|
|
|
@ -35,6 +35,7 @@ import { |
|
|
|
removePersonAbility, |
|
|
|
removePersonAbility, |
|
|
|
addPersonAbility, |
|
|
|
addPersonAbility, |
|
|
|
updatePersonAbility, |
|
|
|
updatePersonAbility, |
|
|
|
|
|
|
|
getSelectCertificateList, |
|
|
|
} from '@/api/productionSchedulingPlan/basic'; |
|
|
|
} from '@/api/productionSchedulingPlan/basic'; |
|
|
|
export default { |
|
|
|
export default { |
|
|
|
components: {}, |
|
|
|
components: {}, |
|
|
|
@ -206,6 +207,41 @@ export default { |
|
|
|
labelWidth: 180, |
|
|
|
labelWidth: 180, |
|
|
|
type: 'number', |
|
|
|
type: 'number', |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
label: '生产标识', |
|
|
|
|
|
|
|
prop: 'productIdent', |
|
|
|
|
|
|
|
search: false, |
|
|
|
|
|
|
|
sortable: true, |
|
|
|
|
|
|
|
span: 12, |
|
|
|
|
|
|
|
// labelWidth: 180, |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
label: '证书类型', |
|
|
|
|
|
|
|
prop: 'certificateId', |
|
|
|
|
|
|
|
search: true, |
|
|
|
|
|
|
|
sortable: true, |
|
|
|
|
|
|
|
span: 12, |
|
|
|
|
|
|
|
type: 'select', |
|
|
|
|
|
|
|
hide:true, |
|
|
|
|
|
|
|
filterable: true, |
|
|
|
|
|
|
|
dicUrl: '/blade-scheduling/personAbility/selectCertificateList', |
|
|
|
|
|
|
|
props: { |
|
|
|
|
|
|
|
label: 'name', |
|
|
|
|
|
|
|
value: 'id', |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
change: (val, row) => { |
|
|
|
|
|
|
|
this.onChangeData(val.item, 'certificateId'); |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
label: '证书类型', |
|
|
|
|
|
|
|
prop: 'certificateName', |
|
|
|
|
|
|
|
search: true, |
|
|
|
|
|
|
|
sortable: true, |
|
|
|
|
|
|
|
span: 12, |
|
|
|
|
|
|
|
display:false, |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
], |
|
|
|
], |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
@ -231,8 +267,15 @@ export default { |
|
|
|
if (val && type == 'craftId') { |
|
|
|
if (val && type == 'craftId') { |
|
|
|
this.form.craftName = val.caName; |
|
|
|
this.form.craftName = val.caName; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
if(val && type == 'certificateId'){ |
|
|
|
|
|
|
|
this.form.certificateName = val.name; |
|
|
|
|
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
rowSave(row, done, loading) { |
|
|
|
rowSave(row, done, loading) { |
|
|
|
|
|
|
|
if(row.productIdent != ''&&row.certificateId == ''){ |
|
|
|
|
|
|
|
loading(); |
|
|
|
|
|
|
|
return this.$message.error('请选择证书类型') |
|
|
|
|
|
|
|
} |
|
|
|
addPersonAbility(row).then( |
|
|
|
addPersonAbility(row).then( |
|
|
|
() => { |
|
|
|
() => { |
|
|
|
this.onLoad(this.page); |
|
|
|
this.onLoad(this.page); |
|
|
|
@ -249,6 +292,11 @@ export default { |
|
|
|
); |
|
|
|
); |
|
|
|
}, |
|
|
|
}, |
|
|
|
rowUpdate(row, index, done, loading) { |
|
|
|
rowUpdate(row, index, done, loading) { |
|
|
|
|
|
|
|
console.log(row,row.productIdent != ''&&(row.certificateId == ''||row.certificateId == undefined)); |
|
|
|
|
|
|
|
if(row.productIdent != ''&&(row.certificateId == ''||row.certificateId == undefined)){ |
|
|
|
|
|
|
|
loading(); |
|
|
|
|
|
|
|
return this.$message.error('请选择证书类型') |
|
|
|
|
|
|
|
} |
|
|
|
updatePersonAbility(row).then( |
|
|
|
updatePersonAbility(row).then( |
|
|
|
() => { |
|
|
|
() => { |
|
|
|
this.onLoad(this.page); |
|
|
|
this.onLoad(this.page); |
|
|
|
|