|
@ -240,31 +240,7 @@ const submitForm = async () => { |
|
|
// 基础数据单表——提交请求 |
|
|
// 基础数据单表——提交请求 |
|
|
formLoading.value = true |
|
|
formLoading.value = true |
|
|
try { |
|
|
try { |
|
|
// const data = unref(formRef)?.formModel as ItempackagingApi.ItempackagingVO |
|
|
|
|
|
const data = unref(formRef)?.formModel |
|
|
const data = unref(formRef)?.formModel |
|
|
// if(props.masterParmas.masterId){ |
|
|
|
|
|
// data.masterId = props.masterParmas.masterId |
|
|
|
|
|
// data.number = props.masterParmas.number |
|
|
|
|
|
// } |
|
|
|
|
|
// console.log(props.formAllSchemas.formSchema) |
|
|
|
|
|
// var isHave = props.formAllSchemas.formSchema.some(function (item) { |
|
|
|
|
|
// return item.field === 'activeTime' || item.field === 'expireTime'; |
|
|
|
|
|
// }); |
|
|
|
|
|
// if(isHave){ |
|
|
|
|
|
// if(data.activeTime && data.expireTime && data.activeTime >=data.expireTime){ |
|
|
|
|
|
// message.error('失效时间要大于生效时间') |
|
|
|
|
|
// return; |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
// if (formType.value === 'create') { |
|
|
|
|
|
// await props.apiCreate(data) |
|
|
|
|
|
// message.success(t('common.createSuccess')) |
|
|
|
|
|
// } else { |
|
|
|
|
|
// await props.apiUpdate(data) |
|
|
|
|
|
// message.success(t('common.updateSuccess')) |
|
|
|
|
|
// } |
|
|
|
|
|
// dialogVisible.value = false |
|
|
|
|
|
// 发送操作成功的事件 |
|
|
|
|
|
emit('success',formType.value,data) |
|
|
emit('success',formType.value,data) |
|
|
} finally { |
|
|
} finally { |
|
|
formLoading.value = false |
|
|
formLoading.value = false |
|
|