From 816b3255f61b453d89d662e56274b3c81d2ff7a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E8=83=9C=E6=A5=A0?= <2792649152@qq.com> Date: Thu, 16 Nov 2023 11:26:56 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BA=93=E5=AD=98=E8=BD=AC=E7=A7=BB=E7=94=B3?= =?UTF-8?q?=E8=AF=B7=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../inventorymoveRequestMain/index.vue | 33 +++++++++++-------- .../inventorymoveRequestMain.data.ts | 24 ++++++++++++-- 2 files changed, 42 insertions(+), 15 deletions(-) diff --git a/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/index.vue b/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/index.vue index 95fb7ad4f..4a8ba5184 100644 --- a/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/index.vue +++ b/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/index.vue @@ -102,12 +102,16 @@ const updataTableColumns = (val) => { const searchTableSuccess = (formField, searchField, val, formRef, type, row ) => { nextTick(() => { if (type == 'tableForm') { - row['fromPackingNumber'] = val[0]['packingNumber'] - row['fromContainerNumber'] = val[0]['containerNumber'] - row['itemCode'] = val[0]['itemCode'] - row['fromBatch'] = val[0]['batch'] - row['fromInventoryStatus'] = val[0]['inventoryStatus'] - row['fromLocationCode'] = val[0]['locationCode'] + if(formField == 'fromPackingNumber'){ + row['fromPackingNumber'] = val[0]['packingNumber'] + row['fromContainerNumber'] = val[0]['containerNumber'] + row['itemCode'] = val[0]['itemCode'] + row['fromBatch'] = val[0]['batch'] + row['fromInventoryStatus'] = val[0]['inventoryStatus'] + row['fromLocationCode'] = val[0]['locationCode'] + } else { + row[formField] = val[0][searchField] + } } else { const setV = {} setV[formField] = val[0][searchField] @@ -119,13 +123,16 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) => const searchTableSuccessDetail = (formField, searchField, val, formRef ) => { nextTick(() => { const setV = {} - setV[formField] = val[0][searchField] - setV['fromPackingNumber'] = val[0]['packingNumber'] - setV['fromContainerNumber'] = val[0]['containerNumber'] - setV['itemCode'] = val[0]['itemCode'] - setV['fromBatch'] = val[0]['batch'] - setV['fromInventoryStatus'] = val[0]['inventoryStatus'] - setV['fromLocationCode'] = val[0]['locationCode'] + if(formField == 'fromPackingNumber') { + setV['fromPackingNumber'] = val[0]['packingNumber'] + setV['fromContainerNumber'] = val[0]['containerNumber'] + setV['itemCode'] = val[0]['itemCode'] + setV['fromBatch'] = val[0]['batch'] + setV['fromInventoryStatus'] = val[0]['inventoryStatus'] + setV['fromLocationCode'] = val[0]['locationCode'] + } else { + setV[formField] = val[0][searchField] + } formRef.setValues(setV) }) } diff --git a/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/inventorymoveRequestMain.data.ts b/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/inventorymoveRequestMain.data.ts index 0854aed05..b73dec95d 100644 --- a/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/inventorymoveRequestMain.data.ts +++ b/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/inventorymoveRequestMain.data.ts @@ -5,6 +5,9 @@ import * as getRequestsettingApi from '@/api/wms/requestsetting/index' import * as BalanceApi from '@/api/wms/balance' import { Balance } from '@/views/wms/inventoryManage/balance/balance.data' +import * as LocationApi from '@/api/wms/location' +import { Location } from '@/views/wms/basicDataManage/factoryModeling/location/location.data' + const { t } = useI18n() // 国际化 // 获取自动提交自动通过自动执行,跳过任务直接删生成记录的默认值 @@ -546,8 +549,25 @@ export const InventorymoveRequestDetail = useCrudSchemas(reactive( table: { width: 150 }, - isTableForm: false, - isForm: false, + tableForm:{ + isInpuFocusShow: true, // 开启查询弹窗 + searchListPlaceholder: '请选择到库位代码', + searchField: 'code', + searchTitle: '库位信息', + searchAllSchemas: Location.allSchemas, + searchPage: LocationApi.getLocationPage + }, + form: { + // labelMessage: '信息提示说明!!!', + componentProps: { + isSearchList: true, // 开启查询弹窗 + searchListPlaceholder: '请选择到库位代码', + searchField: 'code', + searchTitle: '库位信息', + searchAllSchemas: Location.allSchemas, + searchPage: LocationApi.getLocationPage + } + } }, { label: '到库存状态',