From fab6326bf9df3c6db59718bad8f42b0212c73a9e Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期二, 06 一月 2026 15:59:45 +0800
Subject: [PATCH] 双奇点迁移仓库

---
 src/views/basicData/product/index.vue |   32 ++++++++++++++++++--------------
 1 files changed, 18 insertions(+), 14 deletions(-)

diff --git a/src/views/basicData/product/index.vue b/src/views/basicData/product/index.vue
index d71d7cb..68e8221 100644
--- a/src/views/basicData/product/index.vue
+++ b/src/views/basicData/product/index.vue
@@ -55,7 +55,7 @@
                 >
                   缂栬緫
                 </el-button>
-                <el-button type="primary" link @click="openProDia('add', data)">
+                <el-button type="primary" link @click="openProDia('add', data)" :disabled="node.level >= 3">
                   娣诲姞浜у搧
                 </el-button>
                 <el-button
@@ -76,7 +76,7 @@
     <div class="right">
       <div style="margin-bottom: 10px" v-if="isShowButton">
         <el-button type="primary" @click="openModelDia('add')">
-          鏂板瑙勬牸鍨嬪彿
+          鏂板浜у搧楂樺害
         </el-button>
         <ImportExcel @uploadSuccess="getModelList" />
         <el-button
@@ -97,10 +97,9 @@
         @selection-change="handleSelectionChange"
         :tableLoading="tableLoading"
         @pagination="pagination"
-        :total="total"
       ></PIMTable>
     </div>
-    <el-dialog v-model="productDia" title="浜у搧" width="400px">
+    <el-dialog v-model="productDia" title="浜у搧" width="400px" @keydown.enter.prevent>
       <el-form
         :model="form"
         label-width="140px"
@@ -115,6 +114,7 @@
                 v-model="form.productName"
                 placeholder="璇疯緭鍏ヤ骇鍝佸悕绉�"
                 clearable
+                @keydown.enter.prevent
               />
             </el-form-item>
           </el-col>
@@ -129,9 +129,10 @@
     </el-dialog>
     <el-dialog
       v-model="modelDia"
-      title="瑙勬牸鍨嬪彿"
+      title="浜у搧楂樺害"
       width="400px"
       @close="closeModelDia"
+      @keydown.enter.prevent
     >
       <el-form
         :model="modelForm"
@@ -142,22 +143,24 @@
       >
         <el-row>
           <el-col :span="24">
-            <el-form-item label="瑙勬牸鍨嬪彿锛�" prop="model">
+            <el-form-item label="浜у搧楂樺害锛�" prop="model">
               <el-input
                 v-model="modelForm.model"
-                placeholder="璇疯緭鍏ヨ鏍煎瀷鍙�"
+                placeholder="璇疯緭鍏ヤ骇鍝侀珮搴�"
                 clearable
+                @keydown.enter.prevent
               />
             </el-form-item>
           </el-col>
         </el-row>
         <el-row>
           <el-col :span="24">
-            <el-form-item label="鍗曚綅锛�" prop="unit">
+            <el-form-item label="楂樺害鍗曚綅锛�" prop="unit">
               <el-input
                 v-model="modelForm.unit"
-                placeholder="璇疯緭鍏ュ崟浣�"
+                placeholder="璇疯緭鍏ラ珮搴﹀崟浣�"
                 clearable
+                @keydown.enter.prevent
               />
             </el-form-item>
           </el-col>
@@ -202,11 +205,11 @@
 const expandedKeys = ref([]);
 const tableColumn = ref([
   {
-    label: "瑙勬牸鍨嬪彿",
+    label: "浜у搧楂樺害",
     prop: "model",
   },
   {
-    label: "鍗曚綅",
+    label: "楂樺害鍗曚綅",
     prop: "unit",
   },
   {
@@ -227,11 +230,11 @@
 const tableData = ref([]);
 const tableLoading = ref(false);
 const isShowButton = ref(false);
-const total = ref(0);
 const selectedRows = ref([]);
 const page = reactive({
   current: 1,
   size: 10,
+  total: 0,
 });
 const data = reactive({
   form: {
@@ -278,7 +281,7 @@
     form.value.productName = data.productName;
   }
 };
-// 鎵撳紑瑙勬牸鍨嬪彿寮规
+// 鎵撳紑浜у搧楂樺害寮规
 const openModelDia = (type, data) => {
   modelOperationType.value = type;
   modelDia.value = true;
@@ -316,6 +319,7 @@
   proxy.$refs.formRef.resetFields();
   productDia.value = false;
 };
+
 // 鍒犻櫎浜у搧
 const remove = (node, data) => {
   let ids = [];
@@ -388,7 +392,7 @@
   }).then((res) => {
     console.log("res", res);
     tableData.value = res.records;
-    total.value = res.total;
+    page.total = res.total;
     tableLoading.value = false;
   });
 };

--
Gitblit v1.9.3