From f1659a1ecde53251bf9c52bc125b2fb07e36da3b Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期三, 20 五月 2026 14:00:16 +0800
Subject: [PATCH] 进销存pro 1.首页及登录页样式微调 2.添加系统架构图页面 3.优化头部搜索菜单栏功能 4.首页快捷功能跳转路由修改

---
 src/views/productionManagement/productionProcess/index.vue |   27 +++++++++++++++++++++++++--
 1 files changed, 25 insertions(+), 2 deletions(-)

diff --git a/src/views/productionManagement/productionProcess/index.vue b/src/views/productionManagement/productionProcess/index.vue
index 6d007a4..ee49657 100644
--- a/src/views/productionManagement/productionProcess/index.vue
+++ b/src/views/productionManagement/productionProcess/index.vue
@@ -44,7 +44,7 @@
             <div class="card-body">
               <!-- <div class="process-name">{{ process.name }}</div> -->
               <div class="process-desc">{{ process.remark || '鏆傛棤鎻忚堪' }}</div>
-              <div class="process-device">鍏宠仈璁惧: {{ deviceOptions.find(item => item.id === Number(process.deviceLedgerId))?.deviceName|| '鏈叧鑱�' }}</div>
+              <div class="process-device">鍏宠仈璁惧: {{ (deviceOptions.find(item => item.id === Number(process.deviceLedgerId))?.deviceName) || '鏈叧鑱�' }}</div>
             </div>
             <div class="card-footer">
               <div class="status-tag">
@@ -243,6 +243,7 @@
             </el-form-item>
             <el-form-item label="鏍囧噯鍊�">
               <el-input v-model="selectedParam.standardValue"
+                        @input="val => onStandardValueInput(val, selectedParam)"
                         placeholder="璇疯緭鍏ラ粯璁ゅ��" />
             </el-form-item>
           </el-form>
@@ -273,6 +274,7 @@
         <el-form-item label="鏍囧噯鍊�"
                       prop="standardValue">
           <el-input v-model="editParamForm.standardValue"
+                    @input="val => onStandardValueInput(val, editParamForm)"
                     placeholder="璇疯緭鍏ユ爣鍑嗗��" />
         </el-form-item>
       </el-form>
@@ -392,7 +394,18 @@
     technologyParamId: null,
     paramName: "",
     standardValue: null,
+    paramType: null,
   });
+
+  const onStandardValueInput = (val, target) => {
+    const data = target.value || target;
+    const type = data.paramType;
+    if (type === 1) {
+      // 鏁板�兼牸寮忥細涓嶈兘杈撳叆涓枃鎴栬嫳鏂囧瓧绗�
+      data.standardValue = val.replace(/[a-zA-Z\u4e00-\u9fa5]/g, "");
+    }
+  };
+
   const editParamRules = {
     standardValue: [
       {
@@ -403,6 +416,12 @@
           if (value === null || value === undefined || value === "") {
             callback(new Error("璇疯緭鍏ユ爣鍑嗗��"));
           } else {
+            const type = editParamForm.paramType;
+            if (type === 1 && value) {
+              if (/[a-zA-Z\u4e00-\u9fa5]/.test(value)) {
+                return callback(new Error("鏁板�兼牸寮忎笉鑳藉寘鍚腑鑻辨枃瀛楃"));
+              }
+            }
             callback();
           }
         },
@@ -551,7 +570,10 @@
     processForm.isQuality = !!process.isQuality;
     processForm.isProduction = !!process.isProduction;
     processForm.remark = process.remark || "";
-    processForm.deviceLedgerId = Number(process.deviceLedgerId);
+    // 濡傛灉璁惧 ID 涓� 0 鎴栬�呭湪璁惧鍒楄〃涓壘涓嶅埌锛屽垯鍥炴樉涓虹┖锛坣ull锛�
+    const deviceId = Number(process.deviceLedgerId);
+    const hasDevice = deviceOptions.value.some(item => item.id === deviceId);
+    processForm.deviceLedgerId = deviceId && hasDevice ? deviceId : null;
     processForm.type = process.type;
     processDialogVisible.value = true;
   };
@@ -717,6 +739,7 @@
     editParamForm.technologyParamId = row.technologyParamId;
     editParamForm.paramName = row.paramName;
     editParamForm.standardValue = row.standardValue;
+    editParamForm.paramType = row.paramType;
     editParamDialogVisible.value = true;
   };
 

--
Gitblit v1.9.3