From dfb6f8aadd453aa7040958f2ce7835929ffce786 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B7=BB=E7=A0=96-JAVA=5CAdministrator?= <591141169@qq.com> Date: Fri, 8 Mar 2024 14:22:47 +0800 Subject: [PATCH] =?UTF-8?q?BUG=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/eam/item/itemAccounts/index.vue | 7 ++++++- src/views/eam/item/itemApplyMain/index.vue | 16 +++++++++++----- 2 files changed, 17 insertions(+), 6 deletions(-) diff --git a/src/views/eam/item/itemAccounts/index.vue b/src/views/eam/item/itemAccounts/index.vue index 9efea87..a1669bc 100644 --- a/src/views/eam/item/itemAccounts/index.vue +++ b/src/views/eam/item/itemAccounts/index.vue @@ -181,13 +181,18 @@ const submitItem = async (formFieldRef, searchFieldRef, selections, typeRef, row })) ItemAccountsApi.replaceLocation(deviceItemRelList).then((res) => { + message.success(t('更换成功')) + // 刷新列表 + getList() }) } const getItemWithOutBind = async () => { try { const res = await ItemApi.getItemPage({ - ...Item.allSchemas.searchSchema + ...Item.allSchemas.searchSchema, + available:"TRUE" + }) if (res.list?.length > 0) { // const response = await getDeviceItemPage(DeviceAccounts.allSchemas.searchSchema); diff --git a/src/views/eam/item/itemApplyMain/index.vue b/src/views/eam/item/itemApplyMain/index.vue index bb1ec5c..28798d6 100644 --- a/src/views/eam/item/itemApplyMain/index.vue +++ b/src/views/eam/item/itemApplyMain/index.vue @@ -73,12 +73,18 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row) => { nextTick(async () => { if (type == 'tableForm') { + console.log(formField); // 明细查询页赋值 - row[formField] = val[0][searchField] - row['itemNumber'] = val[0]['itemNumber'] - row['isRadeIn'] = val[0]['isRadeIn'] - row['currentQty'] = val[0]['qty'] - row['available'] = val[0]['available'] + if (formField == 'itemNumber') { + row[formField] = val[0][searchField] + row['itemNumber'] = val[0]['itemNumber'] + row['isRadeIn'] = val[0]['isInAccount'] + row['currentQty'] = val[0]['qty'] + row['available'] = val[0]['available'] + } + if (formField == 'deviceNumber') { + row['deviceNumber'] = val[0]['number'] + } } else { const setV = {} setV[formField] = val[0][searchField]