Browse Source

YT-2717:纳入受领书导入添加loading

intex_online20250528
songguoqiang 4 days ago
parent
commit
a1b10ad97b
  1. 13
      src/components/ImportForm/src/ImportFormStep.vue
  2. 52
      src/views/wms/deliversettlementManage/inducedProduct/deliverRecordMain/deliverRecordMain.data.ts

13
src/components/ImportForm/src/ImportFormStep.vue

@ -56,7 +56,7 @@
<div class="warning-message" v-if="active == 1 && !error">
</div>
<div class="table-container">
<div class="table-container" v-loading="isShowLoading">
<Table v-clientTable
:columns="Array.isArray(currentColumns) ? currentColumns : []"
:data="tableObject.tableList"
@ -88,8 +88,8 @@
{{ t('ts.下载差异数据') }}
</el-button>
</div>
<el-button :disabled="formLoading" type="primary" @click="submitForm" v-if="active == 0 || (active == 1 && !error)">{{ t('ts.下一步') }}</el-button>
<el-button :disabled="formLoading" type="primary" @click="submitForm" v-if="active == 2 || (active == 1 && error)">{{ t('ts.好的') }}</el-button>
<el-button :disabled="formLoading || isShowLoading" type="primary" @click="submitForm" v-if="active == 0 || (active == 1 && !error)">{{ t('ts.下一步') }}</el-button>
<el-button :disabled="formLoading || isShowLoading" type="primary" @click="submitForm" v-if="active == 2 || (active == 1 && error)">{{ t('ts.好的') }}</el-button>
<el-button @click="dialogVisible = false">{{ t('ts.取 消') }}</el-button>
</div>
</template>
@ -298,14 +298,17 @@ const open = () => {
defineExpose({ open }) // open
const formRef = ref()
const isShowLoading = ref(false)
/** 提交表单 */
const submitForm = async () => {
//
if (active.value === 1) {
if(error.value){
isShowLoading.value = true
if(error.value){
dialogVisible.value = false
error.value = false
isShowLoading.value = false
}else{
if (props.confirmFormSuccess) {
await props.confirmFormSuccess(props.tableObject.tableList,
@ -313,11 +316,13 @@ const submitForm = async () => {
if(msg){
message.error(msg)
error.value = false
isShowLoading.value = false
return
}else{
message.success("导入成功!")
error.value = false
active.value = 2 //
isShowLoading.value = false
return
}
}

52
src/views/wms/deliversettlementManage/inducedProduct/deliverRecordMain/deliverRecordMain.data.ts

@ -43,24 +43,24 @@ export const DeliverRecordMain = useCrudSchemas(
}
}
},
{
label: '客户订单号',
field: 'customerOrderNumber',
sort: 'custom',
table: {
width: 180
},
isTable: true,
isForm: false,
isSearch: true,
hiddenSearchHigh: true,
search: {
component: 'Input',
componentProps: {
// {
// label: '客户订单号',
// field: 'customerOrderNumber',
// sort: 'custom',
// table: {
// width: 180
// },
// isTable: true,
// isForm: false,
// isSearch: true,
// hiddenSearchHigh: true,
// search: {
// component: 'Input',
// componentProps: {
}
},
},
// }
// },
// },
{
label: '客户代码',
field: 'customerCode',
@ -579,6 +579,24 @@ export const DeliverRecordDetail = useCrudSchemas(reactive<CrudSchema[]>([
isTable: false,
isTableForm: false,
},
{
label: '客户订单号',
field: 'customerOrderNumber',
sort: 'custom',
table: {
width: 180
},
isTable: true,
isForm: false,
isSearch: true,
hiddenSearchHigh: false,
search: {
component: 'Input',
componentProps: {
}
},
},
{
label: '品番',
field: 'itemCode',

Loading…
Cancel
Save