From 7e6232ad426833f894d4314004fa9ceb1c5f1c8f Mon Sep 17 00:00:00 2001
From: liding <756868258@qq.com>
Date: 星期二, 26 五月 2026 10:07:25 +0800
Subject: [PATCH] fix:采购和销售税率添加0并默认
---
src/views/procurementManagement/procurementLedger/index.vue | 20 ++++++++++++++++++--
src/views/salesManagement/salesLedger/index.vue | 17 ++++++++++++++---
2 files changed, 32 insertions(+), 5 deletions(-)
diff --git a/src/views/procurementManagement/procurementLedger/index.vue b/src/views/procurementManagement/procurementLedger/index.vue
index 82ce6c0..f9d12e0 100644
--- a/src/views/procurementManagement/procurementLedger/index.vue
+++ b/src/views/procurementManagement/procurementLedger/index.vue
@@ -566,6 +566,8 @@
placeholder="璇烽�夋嫨"
clearable
@change="mathNum">
+ <el-option label="0"
+ value="0" />
<el-option label="1"
value="1" />
<el-option label="6"
@@ -930,7 +932,7 @@
unit: "",
quantity: "",
taxInclusiveUnitPrice: "",
- taxRate: "",
+ taxRate: "0",
taxInclusiveTotalPrice: "",
taxExclusiveTotalPrice: "",
invoiceType: "",
@@ -1436,7 +1438,21 @@
const openProductForm = async (type, row, index) => {
productOperationType.value = type;
productOperationIndex.value = index;
- productForm.value = {};
+ productForm.value = {
+ productId: "",
+ productCategory: "",
+ productModelId: "",
+ specificationModel: "",
+ unit: "",
+ quantity: "",
+ taxInclusiveUnitPrice: "",
+ taxRate: "0",
+ taxInclusiveTotalPrice: "",
+ taxExclusiveTotalPrice: "",
+ invoiceType: "",
+ warnNum: "",
+ isChecked: true,
+ };
proxy.resetForm("productFormRef");
productFormVisible.value = true;
diff --git a/src/views/salesManagement/salesLedger/index.vue b/src/views/salesManagement/salesLedger/index.vue
index 581139e..df7d288 100644
--- a/src/views/salesManagement/salesLedger/index.vue
+++ b/src/views/salesManagement/salesLedger/index.vue
@@ -360,6 +360,7 @@
<el-col :span="12">
<el-form-item label="绋庣巼(%)锛�" prop="taxRate">
<el-select v-model="productForm.taxRate" placeholder="璇烽�夋嫨" clearable @change="calculateFromTaxRate">
+ <el-option label="0" value="0" />
<el-option label="1" value="1" />
<el-option label="6" value="6" />
<el-option label="13" value="13" />
@@ -733,7 +734,7 @@
unit: "",
quantity: "",
taxInclusiveUnitPrice: "",
- taxRate: "",
+ taxRate: "0",
taxInclusiveTotalPrice: "",
taxExclusiveTotalPrice: "",
invoiceType: "",
@@ -1152,7 +1153,7 @@
productData.value = products.map((p) => {
const quantity = Number(p.quantity ?? 0) || 0;
const unitPrice = Number(p.unitPrice ?? 0) || 0;
- const taxRate = "13"; // 榛樿 13%锛屼究浜庣洿鎺ユ彁浜わ紙濡傞渶鍙湪浜у搧涓嚜琛屼慨鏀癸級
+ const taxRate = "0"; // 榛樿 0%锛屼究浜庣洿鎺ユ彁浜わ紙濡傞渶鍙湪浜у搧涓嚜琛屼慨鏀癸級
const taxInclusiveTotalPrice = (unitPrice * quantity).toFixed(2);
const taxExclusiveTotalPrice = proxy.calculateTaxExclusiveTotalPrice(taxInclusiveTotalPrice, taxRate);
return {
@@ -1251,7 +1252,17 @@
}
productOperationType.value = type;
- productForm.value = {};
+ productForm.value = {
+ productCategory: "",
+ specificationModel: "",
+ unit: "",
+ quantity: "",
+ taxInclusiveUnitPrice: "",
+ taxRate: "0",
+ taxInclusiveTotalPrice: "",
+ taxExclusiveTotalPrice: "",
+ invoiceType: "",
+ };
proxy.resetForm("productFormRef");
if (type === "edit") {
productForm.value = { ...row };
--
Gitblit v1.9.3