|
|
@ -80,11 +80,10 @@ const tableColumns = ref(Packageunit.allSchemas.tableColumns) |
|
|
|
// 查询页面返回 |
|
|
|
const searchTableSuccess = (formField, searchField, val, formRef) => { |
|
|
|
nextTick(() => { |
|
|
|
// if(val[0].parentCode){ |
|
|
|
// message.error('该规格为子包装,请重新选择') |
|
|
|
// return |
|
|
|
// } |
|
|
|
const setV = {} |
|
|
|
if(formField == 'parentCode'){ |
|
|
|
setV['type'] = val[0]['type'] |
|
|
|
} |
|
|
|
setV[formField] = val[0][searchField] |
|
|
|
formRef.setValues(setV) |
|
|
|
}) |
|
|
@ -178,6 +177,9 @@ const openForm = (type: string, row?: any) => { |
|
|
|
if (item.field == 'manageBalance') { |
|
|
|
item.componentProps.disabled = true |
|
|
|
} |
|
|
|
if (item.field == 'type') { |
|
|
|
item.componentProps.disabled = false |
|
|
|
} |
|
|
|
}) |
|
|
|
}else { |
|
|
|
Packageunit.allSchemas.formSchema.forEach((item) => { |
|
|
@ -190,6 +192,9 @@ const openForm = (type: string, row?: any) => { |
|
|
|
if (item.field == 'manageBalance') { |
|
|
|
item.componentProps.disabled = false |
|
|
|
} |
|
|
|
if (item.field == 'type') { |
|
|
|
item.componentProps.disabled = true |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
basicFormRef.value.open(type, row) |
|
|
|