| | |
| | | ref="unitMoreDialog" |
| | | @saveUnitMore="saveUnitMore" |
| | | :workList="unitList" |
| | | :unitRight='editConfig.infomation.unit' |
| | | :dataList="editConfig.infomation.moreUnitList" |
| | | title="启用多单位" |
| | | ></UnitMoreDialog> |
| | |
| | | // 启用多单位的开关 |
| | | moreUnitChange(){ |
| | | let string=false; |
| | | if(this.editConfig.infomation.unit){ |
| | | if(this.editConfig.infomation.moreUnitList&&this.editConfig.infomation.moreUnitList.length>0){ |
| | | for(let i in this.editConfig.infomation.moreUnitList){ |
| | | if(this.editConfig.infomation.moreUnitList[i].unit&&this.editConfig.infomation.moreUnitList[i].amount){ |
| | |
| | | if(!string){ |
| | | this.editConfig.infomation.moreUnit=false |
| | | this.$message.error('请先配置多单位!') |
| | | this.$refs.unitMoreDialog.editDialogVisible = true; |
| | | } |
| | | }else{ |
| | | this.editConfig.infomation.moreUnit=false |
| | | this.$message.error('请先选择单位!') |
| | | } |
| | | |
| | | }, |
| | | handleConfirmSave(dataList) { |
| | | saveUnitDict({ data: dataList }).then((res) => { |
| | |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="2" class="col-name">包</el-col> |
| | | <el-col :span="2" class="col-name">{{unitRight||'--'}}</el-col> |
| | | <el-col :span="5" v-if="index==0"> |
| | | <el-form-item |
| | | label="" |
| | |
| | | workList: { |
| | | type: [Array], |
| | | }, |
| | | unitRight:{ |
| | | type: String, |
| | | }, |
| | | }, |
| | | data() { |
| | | return { |
| | |
| | | this.editConfig.autoEdit = true |
| | | this.editConfig.title = "编辑" |
| | | let imageSrc = row.attachmentList?.length > 0 ? row.attachmentList[0].FileUrl : "" |
| | | this.editConfig.infomation = { ...row, imageSrc: imageSrc } |
| | | this.editConfig.infomation = { ...row, imageSrc: imageSrc,moreUnitList:row.moreUnitList?row.moreUnitList:[] } |
| | | this.editConfig.visible = true |
| | | }, |
| | | // 切换列表展现形式 |