|
|
@ -199,14 +199,17 @@ const formsSuccess = async (formType,data) => { |
|
|
|
return |
|
|
|
} |
|
|
|
basicFormRef.value.formLoading = true |
|
|
|
if (formType === 'create') { |
|
|
|
await BomApi.createBom(data) |
|
|
|
message.success(t('common.createSuccess')) |
|
|
|
} else { |
|
|
|
await BomApi.updateBom(data) |
|
|
|
message.success(t('common.updateSuccess')) |
|
|
|
try { |
|
|
|
if (formType === 'create') { |
|
|
|
await BomApi.createBom(data) |
|
|
|
message.success(t('common.createSuccess')) |
|
|
|
} else { |
|
|
|
await BomApi.updateBom(data) |
|
|
|
message.success(t('common.updateSuccess')) |
|
|
|
} |
|
|
|
} finally { |
|
|
|
basicFormRef.value.formLoading = false |
|
|
|
} |
|
|
|
basicFormRef.value.formLoading = false |
|
|
|
basicFormRef.value.dialogVisible = false |
|
|
|
if (formType === 'create') { |
|
|
|
getList() |
|
|
|