Browse Source

优化组件显示

master
陈裕财 3 years ago
parent
commit
6eb4b1b478
  1. 12
      src/components/MdpSelectDictX/index.vue

12
src/components/MdpSelectDictX/index.vue

@ -44,10 +44,18 @@ export default {
components: {},
computed: {
currentItem(){
if(this.myVal===''||this.myVal===null){
return {id:'',name:'无',className:'info'};
}
if(this.dict){
return this.dict.find((k) => k.id == this.myVal);
var item= this.dict.find(k=>k.id==this.myVal)
if(item){
return item
}else{
return {id:this.myVal,name:this.myVal,className:'info'}
}
}else{
return null;
return {id:this.myVal,name:this.myVal,className:'info'};
}
},
avaterCpd() {

Loading…
Cancel
Save