|
@ -194,10 +194,10 @@ const formsSuccess = async (formType, data) => { |
|
|
data.inInventoryStatuses = data.inInventoryStatuses.join(',') |
|
|
data.inInventoryStatuses = data.inInventoryStatuses.join(',') |
|
|
if (formType === 'create') { |
|
|
if (formType === 'create') { |
|
|
await BusinesstypeApi.createBusinesstype(data) |
|
|
await BusinesstypeApi.createBusinesstype(data) |
|
|
.then(() => { |
|
|
.then(async () => { |
|
|
message.success(t('common.createSuccess')) |
|
|
message.success(t('common.createSuccess')) |
|
|
basicFormRef.value.dialogVisible = false |
|
|
basicFormRef.value.dialogVisible = false |
|
|
getList() |
|
|
await getList() |
|
|
}) |
|
|
}) |
|
|
.catch(() => { |
|
|
.catch(() => { |
|
|
data.itemTypes = data.itemTypes.split(',') |
|
|
data.itemTypes = data.itemTypes.split(',') |
|
@ -208,10 +208,10 @@ const formsSuccess = async (formType, data) => { |
|
|
}) |
|
|
}) |
|
|
} else { |
|
|
} else { |
|
|
await BusinesstypeApi.updateBusinesstype(data) |
|
|
await BusinesstypeApi.updateBusinesstype(data) |
|
|
.then(() => { |
|
|
.then(async () => { |
|
|
message.success(t('common.updateSuccess')) |
|
|
message.success(t('common.updateSuccess')) |
|
|
basicFormRef.value.dialogVisible = false |
|
|
basicFormRef.value.dialogVisible = false |
|
|
getList() |
|
|
await getList() |
|
|
}) |
|
|
}) |
|
|
.catch(() => { |
|
|
.catch(() => { |
|
|
data.itemTypes = data.itemTypes.split(',') |
|
|
data.itemTypes = data.itemTypes.split(',') |
|
@ -296,7 +296,7 @@ const searchFormClick = (searchData) => { |
|
|
/** 初始化 **/ |
|
|
/** 初始化 **/ |
|
|
onMounted(async () => { |
|
|
onMounted(async () => { |
|
|
await getList() |
|
|
await getList() |
|
|
// console.log(300, tableObject.tableList) |
|
|
|
|
|
importTemplateData.templateUrl = await BusinesstypeApi.importTemplate() |
|
|
importTemplateData.templateUrl = await BusinesstypeApi.importTemplate() |
|
|
}) |
|
|
}) |
|
|
</script> |
|
|
</script> |
|
|