From a974cff29f2495edc6f2788240aec2e51bd6f1d4 Mon Sep 17 00:00:00 2001
From: liu <2021943741@qq.com>
Date: 星期四, 24 九月 2026 19:06:46 +0800
Subject: [PATCH] feat(生产核算): 前端适配「中提琴」大类与折算率配置

---
 src/views/productionManagement/productionProcess/index.vue                       |   28 ++++++++++++++++++++++++++++
 src/views/productionManagement/productionReportingEntry/index.vue                |    1 +
 src/views/productionManagement/productionReporting/index.vue                     |    1 +
 src/views/productionManagement/productionCosting/index.vue                       |    2 ++
 src/views/productionManagement/productionCosting/components/CostConfigDialog.vue |    8 ++++++--
 5 files changed, 38 insertions(+), 2 deletions(-)

diff --git a/src/views/productionManagement/productionCosting/components/CostConfigDialog.vue b/src/views/productionManagement/productionCosting/components/CostConfigDialog.vue
index 03b142e..0e63754 100644
--- a/src/views/productionManagement/productionCosting/components/CostConfigDialog.vue
+++ b/src/views/productionManagement/productionCosting/components/CostConfigDialog.vue
@@ -66,6 +66,7 @@
           <el-table-column label="宸ュ簭" prop="processName" min-width="110" />
           <el-table-column label="鍛樺伐" prop="staffName" min-width="110" />
           <el-table-column label="灏忔彁鐞存姌绠楃巼" prop="violinFactor" min-width="110" />
+          <el-table-column label="涓彁鐞存姌绠楃巼" prop="midViolinFactor" min-width="110" />
           <el-table-column label="澶ф彁鐞存姌绠楃巼" prop="violaFactor" min-width="110" />
           <el-table-column label="璐濇柉鎶樼畻鐜�" prop="bassFactor" min-width="100" />
           <el-table-column label="鎿嶄綔" width="140" fixed="right">
@@ -174,6 +175,9 @@
         </el-form-item>
         <el-form-item label="灏忔彁鐞存姌绠楃巼">
           <el-input-number v-model="factorForm.violinFactor" :min="0" :precision="4" style="width: 100%" />
+        </el-form-item>
+        <el-form-item label="涓彁鐞存姌绠楃巼">
+          <el-input-number v-model="factorForm.midViolinFactor" :min="0" :precision="4" style="width: 100%" />
         </el-form-item>
         <el-form-item label="澶ф彁鐞存姌绠楃巼">
           <el-input-number v-model="factorForm.violaFactor" :min="0" :precision="4" style="width: 100%" />
@@ -340,12 +344,12 @@
   /* ---------- 鎶樼畻鐜� ---------- */
   const factorFormVisible = ref(false);
   const factorForm = reactive({
-    id: null, processId: null, staffId: null, staffName: "", violinFactor: 1, violaFactor: 1, bassFactor: 1, remark: "",
+    id: null, processId: null, staffId: null, staffName: "", violinFactor: 1, midViolinFactor: 1, violaFactor: 1, bassFactor: 1, remark: "",
   });
   const openFactorForm = row => {
     Object.assign(factorForm, {
       id: null, processId: factorQuery.processId || null, staffId: null, staffName: "",
-      violinFactor: 1, violaFactor: 1, bassFactor: 1, remark: "",
+      violinFactor: 1, midViolinFactor: 1, violaFactor: 1, bassFactor: 1, remark: "",
     }, row || {});
     factorFormVisible.value = true;
   };
diff --git a/src/views/productionManagement/productionCosting/index.vue b/src/views/productionManagement/productionCosting/index.vue
index d19462b..abd86a1 100644
--- a/src/views/productionManagement/productionCosting/index.vue
+++ b/src/views/productionManagement/productionCosting/index.vue
@@ -139,8 +139,10 @@
       { label: "鐢熶骇浜�", prop: "staffName", minWidth: 90 },
       { label: "宸ュ簭", prop: "processName", minWidth: 80 },
       { label: "灏忔彁鐞存暟閲�", prop: "violinQty", minWidth: 90 },
+      { label: "涓彁鐞存暟閲�", prop: "violaQty", minWidth: 90 },
       { label: "澶ф彁鐞存暟閲�", prop: "celloQty", minWidth: 90 },
       { label: "璐濇柉鏁伴噺", prop: "bassQty", minWidth: 80 },
+      { label: "涓彁鎶樼畻鐜�", prop: "violaFactor", minWidth: 90 },
       { label: "澶ф彁鎶樼畻鐜�", prop: "celloFactor", minWidth: 90 },
       { label: "璐濇柉鎶樼畻鐜�", prop: "bassFactor", minWidth: 90 },
       { label: "鏈堜骇鎶樺悎灏忔彁鐞�", prop: "foldedQuantity", minWidth: 120 },
diff --git a/src/views/productionManagement/productionProcess/index.vue b/src/views/productionManagement/productionProcess/index.vue
index 9b1ae12..53c42fc 100644
--- a/src/views/productionManagement/productionProcess/index.vue
+++ b/src/views/productionManagement/productionProcess/index.vue
@@ -134,6 +134,13 @@
                     :step="0.001"
                     placeholder="璇疯緭鍏ュ皬鎻愮惔绯绘暟" />
         </el-form-item>
+        <el-form-item label="涓彁鐞寸郴鏁�"
+                      prop="midViolinFactor">
+          <el-input v-model="processForm.midViolinFactor"
+                    type="number"
+                    :step="0.001"
+                    placeholder="璇疯緭鍏ヤ腑鎻愮惔绯绘暟" />
+        </el-form-item>
         <el-form-item label="澶ф彁鐞寸郴鏁�"
                       prop="violaFactor">
           <el-input v-model="processForm.violaFactor"
@@ -369,6 +376,7 @@
     name: "",
     standardQuantity: null,
     violinFactor: null,
+    midViolinFactor: null,
     violaFactor: null,
     bassFactor: null,
     isQuality: false,
@@ -410,6 +418,24 @@
           }
           if (isNaN(value) || value < 0) {
             callback(new Error("灏忔彁鐞寸郴鏁板繀椤绘槸闈炶礋鏁板瓧"));
+          } else {
+            callback();
+          }
+        },
+      },
+    ],
+    midViolinFactor: [
+      {
+        required: false,
+        message: "璇疯緭鍏ヤ腑鎻愮惔绯绘暟",
+        trigger: "blur",
+        validator: (rule, value, callback) => {
+          if (value == null || value === "") {
+            callback();
+            return;
+          }
+          if (isNaN(value) || value < 0) {
+            callback(new Error("涓彁鐞寸郴鏁板繀椤绘槸闈炶礋鏁板瓧"));
           } else {
             callback();
           }
@@ -654,6 +680,7 @@
     processForm.name = "";
     processForm.standardQuantity = null;
     processForm.violinFactor = null;
+    processForm.midViolinFactor = null;
     processForm.violaFactor = null;
     processForm.bassFactor = null;
     processForm.isQuality = false;
@@ -671,6 +698,7 @@
     processForm.name = process.name;
     processForm.standardQuantity = process.standardQuantity;
     processForm.violinFactor = process.violinFactor;
+    processForm.midViolinFactor = process.midViolinFactor;
     processForm.violaFactor = process.violaFactor;
     processForm.bassFactor = process.bassFactor;
     processForm.isQuality = !!process.isQuality;
diff --git a/src/views/productionManagement/productionReporting/index.vue b/src/views/productionManagement/productionReporting/index.vue
index ccdf5b5..fa0df48 100644
--- a/src/views/productionManagement/productionReporting/index.vue
+++ b/src/views/productionManagement/productionReporting/index.vue
@@ -39,6 +39,7 @@
                      style="width: 200px;"
                      @change="handleQuery">
             <el-option label="灏忔彁鐞�" value="灏忔彁鐞�" />
+            <el-option label="涓彁鐞�" value="涓彁鐞�" />
             <el-option label="澶ф彁鐞�" value="澶ф彁鐞�" />
             <el-option label="璐濇柉" value="璐濇柉" />
           </el-select>
diff --git a/src/views/productionManagement/productionReportingEntry/index.vue b/src/views/productionManagement/productionReportingEntry/index.vue
index 34edcf7..410158f 100644
--- a/src/views/productionManagement/productionReportingEntry/index.vue
+++ b/src/views/productionManagement/productionReportingEntry/index.vue
@@ -51,6 +51,7 @@
                      placeholder="璇烽�夋嫨"
                      @change="handleQuery">
             <el-option label="灏忔彁鐞�" value="灏忔彁鐞�" />
+            <el-option label="涓彁鐞�" value="涓彁鐞�" />
             <el-option label="澶ф彁鐞�" value="澶ф彁鐞�" />
             <el-option label="璐濇柉" value="璐濇柉" />
           </el-select>

--
Gitblit v1.9.3