From f9407ca8bcd2beeb533ad4e35c5ff8a1e7a18e88 Mon Sep 17 00:00:00 2001 From: nehc <934298133@qq.com> Date: Wed, 23 Jul 2025 22:26:42 +0800 Subject: [PATCH] =?UTF-8?q?feat(@vben/web-antd):=20erp-=E9=87=87=E8=B4=AD?= =?UTF-8?q?=E8=AE=A2=E5=8D=95=E6=98=8E=E7=BB=86=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 优化了产品变更、价格计算和表单验证逻辑 - 更新了表格列定义和单元格模板 - 删除了冗余的组件挂载逻辑 --- .../order/modules/PurchaseOrderItemForm.vue | 383 ++++++++---------- .../views/erp/purchase/order/modules/form.vue | 20 +- 2 files changed, 186 insertions(+), 217 deletions(-) diff --git a/apps/web-antd/src/views/erp/purchase/order/modules/PurchaseOrderItemForm.vue b/apps/web-antd/src/views/erp/purchase/order/modules/PurchaseOrderItemForm.vue index e89ada9c..158549f4 100644 --- a/apps/web-antd/src/views/erp/purchase/order/modules/PurchaseOrderItemForm.vue +++ b/apps/web-antd/src/views/erp/purchase/order/modules/PurchaseOrderItemForm.vue @@ -1,15 +1,11 @@ @@ -263,100 +240,84 @@ defineExpose({ validate, getData, init }); :scroll="{ x: 1400 }" > - + + onChangeProduct(value, index)" class="w-full" > - {{ item.name }} + {{ product.name }} + {{ record.productName || '-' }} - - {{ record.stockCount || 0 }} - - - {{ record.productBarCode }} - - - {{ record.productUnitName }} - - + + + - - - onCountChange(value, index)" class="w-full" /> + {{ record.count || '-' }} - + + + onPriceChange(value, index)" class="w-full" /> + {{ record.productPrice || '-' }} - + + + onTaxPercentChange(value, index)" class="w-full" /> + {{ record.taxPercent || '-' }} - - - - - - - - + + + onRemarkChange((e.target as HTMLInputElement).value, index) + " + class="w-full" /> + {{ record.remark || '-' }} - + + + 合计: 数量:{{ getSummaries().count }} - 金额:{{ getSummaries().totalPrice }} + 金额:{{ getSummaries().totalProductPrice }} 税额:{{ getSummaries().taxPrice }} - 税额合计:{{ getSummaries().totalTaxPrice }} + 税额合计:{{ getSummaries().totalPrice }} diff --git a/apps/web-antd/src/views/erp/purchase/order/modules/form.vue b/apps/web-antd/src/views/erp/purchase/order/modules/form.vue index 67f4ee2f..93d62604 100644 --- a/apps/web-antd/src/views/erp/purchase/order/modules/form.vue +++ b/apps/web-antd/src/views/erp/purchase/order/modules/form.vue @@ -129,11 +129,19 @@ defineExpose({ modalApi }); > - - + + + + + + + + + +