From 00b847c33c3ffe57aaab066edf6745a6a85c506f Mon Sep 17 00:00:00 2001 From: hwj Date: Mon, 22 Jun 2026 14:09:43 +0800 Subject: [PATCH] =?UTF-8?q?style=EF=BC=9A=E6=89=98=E7=9B=98=E7=AE=A1?= =?UTF-8?q?=E7=90=86-=E6=96=B0=E5=A2=9E/=E7=BC=96=E8=BE=91-=E5=8D=95?= =?UTF-8?q?=E4=BD=8D=E6=94=B9=E6=88=90=E4=B8=8B=E6=8B=89=E6=A1=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/erp/stock/pallet/PalletForm.vue | 27 +++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) diff --git a/src/views/erp/stock/pallet/PalletForm.vue b/src/views/erp/stock/pallet/PalletForm.vue index 83f27307..effdc6ce 100644 --- a/src/views/erp/stock/pallet/PalletForm.vue +++ b/src/views/erp/stock/pallet/PalletForm.vue @@ -86,7 +86,20 @@ - + + + @@ -359,6 +372,7 @@ import { dateFormatter } from '@/utils/formatTime' import { WarehouseApi, WarehouseVO } from '@/api/erp/stock/warehouse' import { WarehouseAreaApi, WarehouseAreaVO } from '@/api/erp/stock/warehousearea' import { ProductApi, ProductVO } from '@/api/erp/product/product' +import { ProductUnitApi, ProductUnitVO } from '@/api/erp/product/unit' import QrcodeActionCard from '@/components/QrcodeActionCard/index.vue' defineOptions({ name: 'PalletForm' }) @@ -374,6 +388,7 @@ const formRef = ref() const warehouseOptions = ref([]) const areaOptions = ref([]) const productList = ref([]) +const unitList = ref([]) const selectedWarehouse = ref() const selectedArea = ref() @@ -406,7 +421,7 @@ const formData = ref({ palletType: undefined, specification: undefined, ratedLoadWeight: undefined, - unit: 'kg', + unit: undefined, status: undefined, warehouseId: undefined, areaId: undefined, @@ -450,7 +465,7 @@ const open = async (type: string, row?: PalletVO) => { dialogTitle.value = t('action.' + type) formType.value = type resetForm() - await Promise.all([getWarehouseOptions(), getAreaOptions(), getProductList()]) + await Promise.all([getWarehouseOptions(), getAreaOptions(), getProductList(), getUnitList()]) if (type === 'update' && row) { formData.value = { ...row, @@ -500,6 +515,10 @@ const getProductList = async () => { productList.value = await ProductApi.getProductSimpleList() } +const getUnitList = async () => { + unitList.value = await ProductUnitApi.getProductUnitSimpleList() +} + const buildPrintData = () => { return { id: formData.value.id, @@ -670,7 +689,7 @@ const resetForm = () => { palletType: undefined, specification: undefined, ratedLoadWeight: undefined, - unit: 'kg', + unit: undefined, status: undefined, warehouseId: undefined, areaId: undefined,