From a80d418d5d985af44565058c56c061b2b4c4fa43 Mon Sep 17 00:00:00 2001
From: cuijian <cuijian@xalxzn.com>
Date: 星期三, 03 九月 2025 16:51:24 +0800
Subject: [PATCH] 参数录入增加数据字典选择,查询列表增加字典翻译

---
 src/views/tms/modules/baseTools/ParaBladeModal.vue |  239 ++++++++++++++++++++++++++++++++++++++++++++++-------------
 1 files changed, 185 insertions(+), 54 deletions(-)

diff --git a/src/views/tms/modules/baseTools/ParaBladeModal.vue b/src/views/tms/modules/baseTools/ParaBladeModal.vue
index aa2a9f8..734f943 100644
--- a/src/views/tms/modules/baseTools/ParaBladeModal.vue
+++ b/src/views/tms/modules/baseTools/ParaBladeModal.vue
@@ -68,6 +68,7 @@
                     :placeholder="disableSubmit ? '' : '璇疯緭鍏ヤ腑鏂囧悕绉�'"
                     v-model="model.chineseName"
                     :disabled="disableSubmit"
+                    @change="(e) => chineseNameChange(e.target.value)"
                   />
                 </a-form-model-item>
               </a-col>
@@ -90,6 +91,7 @@
                     :placeholder="disableSubmit ? '' : '璇疯緭鍏ュ瀷鍙�/鍥惧彿'"
                     v-model="model.toolModel"
                     :disabled="disableSubmit"
+                    @change="(e) => toolModelChange(e.target.value)"
                   />
                 </a-form-model-item>
               </a-col>
@@ -131,17 +133,6 @@
               </a-col>
             </a-row>
           </a-col>
-          <a-col :span="8">
-            <a-form-model-item prop="accuracyClass" label="绮惧害绛夌骇">
-              <j-dict-select-tag
-                type="list"
-                v-model="model.accuracyClass"
-                :triggerChange="true"
-                dictCode="accuracy_class"
-                :placeholder="disableSubmit ? '' : '璇烽�夋嫨绮惧害绛夌骇'"
-              />
-            </a-form-model-item>
-          </a-col>
 
           <a-col :span="6">
             <a-row>
@@ -162,7 +153,7 @@
           <a-col :span="8">
             <a-form-model-item prop="applicationType" label="宸ュ叿绫诲瀷">
               <j-dict-select-tag
-                dict-code="equipment_category"
+                dict-code="application_type"
                 :placeholder="disableSubmit ? '' : '璇烽�夋嫨宸ュ叿绫诲瀷'"
                 v-model="model.applicationType"
                 :disabled="disableSubmit"
@@ -204,15 +195,6 @@
 
         <a-row :gutter="24">
           <a-col :span="8">
-            <a-form-model-item prop="storageLocation" label="瀛樺偍浣嶇疆">
-              <a-input
-                :placeholder="disableSubmit ? '' : '璇疯緭鍏ュ瓨鍌ㄤ綅缃�'"
-                v-model="model.storageLocation"
-                :disabled="disableSubmit"
-              />
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="8">
             <a-form-model-item prop="lowerInventory" label="鏈�浣庡簱瀛�">
               <a-input
                 :placeholder="disableSubmit ? '' : '璇疯緭鍏ユ渶浣庡簱瀛�'"
@@ -230,9 +212,6 @@
               />
             </a-form-model-item>
           </a-col>
-        </a-row>
-
-        <a-row :gutter="24">
           <a-col :span="8">
             <a-form-model-item prop="auxiliaryUnitFlag" label="鏄惁鏈夎閲忚緟鍗曚綅">
               <a-radio-group
@@ -245,6 +224,9 @@
               </a-radio-group>
             </a-form-model-item>
           </a-col>
+        </a-row>
+
+        <a-row :gutter="24">
           <a-col :span="8">
             <a-form-model-item prop="mainUnit" label="璁¢噺涓诲崟浣�">
               <a-input
@@ -263,9 +245,6 @@
               />
             </a-form-model-item>
           </a-col>
-        </a-row>
-
-        <a-row :gutter="24">
           <a-col :span="8">
             <a-form-model-item prop="supplierId" label="鍘傚">
               <a-input
@@ -275,6 +254,9 @@
               />
             </a-form-model-item>
           </a-col>
+        </a-row>
+
+        <a-row :gutter="24">
           <a-col :span="8">
             <a-form-model-item prop="price" label="鍗曚环">
               <a-input
@@ -297,12 +279,51 @@
 
         <a-row :gutter="24">
           <a-col :span="6">
-            <a-form-model-item label="鍒�鐗囧舰鐘�" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="bladeShape">
+            <a-form-model-item label="宸ュ叿绠�绉�" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="shortCalled">
               <a-input
-                v-model="model.bladeShape"
-                :placeholder="disableSubmit ? '' : '璇疯緭鍏ュ垁鐗囧舰鐘�'"
+                v-model="model.shortCalled"
+                :placeholder="disableSubmit ? '' : '璇疯緭鍏ュ伐鍏风畝绉�'"
                 :disabled="disableSubmit"
               ></a-input>
+            </a-form-model-item>
+          </a-col>
+          <a-col :span="6">
+            <a-form-model-item
+              label="闆嗗洟鍏徃缂栫爜"
+              :labelCol="labelCol"
+              :wrapperCol="wrapperCol"
+              prop="groupCompanyCode"
+            >
+              <a-input
+                v-model="model.groupCompanyCode"
+                :placeholder="disableSubmit ? '' : '璇疯緭鍏ラ泦鍥㈠叕鍙哥紪鐮�'"
+                :disabled="disableSubmit"
+              ></a-input>
+            </a-form-model-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-model-item
+              label="闆嗗洟鍏徃鏍囪"
+              :labelCol="{ span: 4 }"
+              :wrapperCol="{ span: 20 }"
+              prop="groupCompanySign"
+            >
+              <a-input v-model="model.groupCompanySign" :disabled="true"></a-input>
+            </a-form-model-item>
+          </a-col>
+        </a-row>
+
+        <a-row :gutter="24">
+          <a-col :span="6">
+            <a-form-model-item label="鍒�鐗囧舰鐘�" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="bladeShape">
+              <j-dict-select-tag
+                type="list"
+                v-model="model.bladeShape"
+                :triggerChange="true"
+                dictCode="blade_shape"
+                placeholder="璇烽�夋嫨鍒�鐗囧舰鐘�"
+                :disabled="disableSubmit"
+              />
             </a-form-model-item>
           </a-col>
           <a-col :span="6">
@@ -311,6 +332,7 @@
                 v-model="model.bladeLength"
                 :placeholder="disableSubmit ? '' : '璇疯緭鍏ュ垁鐗囬暱搴�'"
                 :disabled="disableSubmit"
+                @change="(e) => bladeLengthChange(e.target.value)"
               ></a-input>
             </a-form-model-item>
           </a-col>
@@ -320,6 +342,7 @@
                 v-model="model.cuttingEdgeCount"
                 :placeholder="disableSubmit ? '' : '璇疯緭鍏ュ垏鍓婂垉鏁�'"
                 :disabled="disableSubmit"
+                @change="(e) => cuttingEdgeCountChange(e.target.value)"
               ></a-input>
             </a-form-model-item>
           </a-col>
@@ -337,11 +360,14 @@
         <a-row :gutter="24">
           <a-col :span="6">
             <a-form-model-item label="澶瑰浐鍨嬪紡" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="clampingType">
-              <a-input
+             <j-dict-select-tag
+                type="list"
                 v-model="model.clampingType"
-                :placeholder="disableSubmit ? '' : '璇疯緭鍏ュす鍥哄瀷寮�'"
+                :triggerChange="true"
+                dictCode="clamping_type"
+                placeholder="璇烽�夋嫨澶瑰浐鍨嬪紡"
                 :disabled="disableSubmit"
-              ></a-input>
+              />
             </a-form-model-item>
           </a-col>
           <a-col :span="6">
@@ -350,16 +376,20 @@
                 v-model="model.noseAngleR"
                 :placeholder="disableSubmit ? '' : '璇疯緭鍏ュ垁灏朢'"
                 :disabled="disableSubmit"
+                @change="(e) => noseAngleRChange(e.target.value)"
               ></a-input>
             </a-form-model-item>
           </a-col>
           <a-col :span="6">
             <a-form-model-item label="鍒�鐗囨潗鏂�" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="toolMaterial">
-              <a-input
+              <j-dict-select-tag
+                type="list"
                 v-model="model.toolMaterial"
-                :placeholder="disableSubmit ? '' : '璇疯緭鍏ュ垁鐗囨潗鏂�'"
+                :triggerChange="true"
+                dictCode="tool_material"
+                placeholder="璇烽�夋嫨鍒�鐗囨潗鏂�"
                 :disabled="disableSubmit"
-              ></a-input>
+              />
             </a-form-model-item>
           </a-col>
           <a-col :span="6">
@@ -402,8 +432,8 @@
           <a-col :span="6">
             <a-form-model-item
               label="闄勫姞鎶�鏈潯浠惰鏄�"
-              :labelCol="labelCol"
-              :wrapperCol="wrapperCol"
+              :labelCol="{ span: 12 }"
+              :wrapperCol="{ span: 12 }"
               prop="conditionsInfo"
             >
               <a-input
@@ -435,11 +465,14 @@
           </a-col>
           <a-col :span="6">
             <a-form-model-item label="鍒跺紡" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="types">
-              <a-input
+              <j-dict-select-tag
+                type="list"
                 v-model="model.types"
-                :placeholder="disableSubmit ? '' : '璇疯緭鍏ュ埗寮�'"
+                :triggerChange="true"
+                dictCode="types"
+                placeholder="璇烽�夋嫨鍒跺紡"
                 :disabled="disableSubmit"
-              ></a-input>
+              />
             </a-form-model-item>
           </a-col>
           <a-col :span="6">
@@ -464,11 +497,14 @@
         <a-row>
           <a-col :span="6">
             <a-form-model-item label="鍒囧墛鏂瑰悜" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="cuttingDirection">
-              <a-input
+              <j-dict-select-tag
+                type="list"
                 v-model="model.cuttingDirection"
-                :placeholder="disableSubmit ? '' : '璇疯緭鍏ュ垏鍓婃柟鍚�'"
+                :triggerChange="true"
+                dictCode="cutting_direction"
+                placeholder="璇烽�夋嫨鍒囧墛鏂瑰悜"
                 :disabled="disableSubmit"
-              ></a-input>
+              />
             </a-form-model-item>
           </a-col>
           <a-col :span="6">
@@ -491,22 +527,28 @@
           </a-col>
           <a-col :span="6">
             <a-form-model-item label="鍐呭铻虹汗" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="inOutThread">
-              <a-input
+              <j-dict-select-tag
+                type="list"
                 v-model="model.inOutThread"
-                :placeholder="disableSubmit ? '' : '璇疯緭鍏ュ唴澶栬灪绾�'"
+                :triggerChange="true"
+                dictCode="in_out_thread"
+                placeholder="璇烽�夋嫨鍐呭铻虹汗"
                 :disabled="disableSubmit"
-              ></a-input>
+              />
             </a-form-model-item>
           </a-col>
         </a-row>
         <a-row>
           <a-col :span="6">
             <a-form-model-item label="铻虹汗鏍囧噯" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="threadStandard">
-              <a-input
+             <j-dict-select-tag
+                type="list"
                 v-model="model.threadStandard"
-                :placeholder="disableSubmit ? '' : '璇疯緭鍏ヨ灪绾规爣鍑�'"
+                :triggerChange="true"
+                dictCode="tool_thread_standard"
+                placeholder="璇烽�夋嫨铻虹汗鏍囧噯"
                 :disabled="disableSubmit"
-              ></a-input>
+              />
             </a-form-model-item>
           </a-col>
           <a-col :span="6">
@@ -530,8 +572,8 @@
           <a-col :span="6">
             <a-form-model-item
               label="鏈�灏忓姞宸ュ唴铻虹汗鍏О鐩村緞"
-              :labelCol="labelCol"
-              :wrapperCol="wrapperCol"
+              :labelCol="{ span: 15 }"
+              :wrapperCol="{ span: 9 }"
               prop="minInternalThread"
             >
               <a-input
@@ -612,12 +654,20 @@
         toolMaterial: [{ required: true, message: '璇疯緭鍏ュ垁鐗囨潗鏂�' }],
         paintcoatFlag: [{ required: true, message: '璇烽�夋嫨鏄惁娑傚眰' }],
         technicalConditions: [{ required: true, message: '璇疯緭鍏ラ檮鍔犳妧鏈潯浠�' }],
+        shortCalled: [{ required: true, message: '璇疯緭鍏ュ伐鍏风畝绉�' }],
       },
       url: {
         add: '/tms/baseTools/add',
         edit: '/tms/baseTools/edit',
+        queryParaByToolCode: '/tms/baseTools/queryByToolCode',
       },
       locationCodeOptions: [],
+      chineseNameChange1: '',
+      toolModelChange1: '',
+      bladeShapeChange1: '',
+      bladeLengthChange1: '',
+      cuttingEdgeCountChange1: '',
+      noseAngleRChange1: '',
     }
   },
   created() {
@@ -637,8 +687,8 @@
       this.editable = false
       //鍒濆鍖栭粯璁ゅ��
       this.model = {
-        positionCode: '' 
-      };
+        positionCode: '',
+      }
       this.model.classifyId = nodeSelected.key
       this.model.classifyNum = nodeSelected.entity.classifyId
       this.model.classifyName = nodeSelected.entity.typeName
@@ -648,12 +698,33 @@
     edit(record) {
       this.editable = true
       this.model = Object.assign({}, record)
+      this.chineseNameChange1 = record.chineseName
+      this.toolModelChange1 = '-' + record.toolModel
+      this.bladeShapeChange1 = '-' + record.bladeShape
+      this.bladeLengthChange1 = '-' + record.bladeLength
+      this.cuttingEdgeCountChange1 = '-' + record.cuttingEdgeCount
+      this.noseAngleRChange1 = '-' + record.noseAngleR
+      //閫氳繃id鏌ヨ绠$悊鍙傛暟鍜屽弬鏁版暟鎹�
+      // getAction(this.url.queryParaByToolCode, {
+      //   toolCode: record.toolCodeId,
+      //   paraTypeFlag: record.paraTypeFlag,
+      // }).then((res) => {
+      //   if (res.success) {
+      //     this.model = Object.assign({}, res.result)
+      //   }
+      // })
       this.visible = true
     },
     close() {
       this.$emit('close')
       this.visible = false
       this.$refs.form.clearValidate()
+      ;(this.chineseNameChange1 = ''),
+        (this.toolModelChange1 = ''),
+        (this.bladeShapeChange1 = ''),
+        (this.bladeLengthChange1 = ''),
+        (this.cuttingEdgeCountChange1 = ''),
+        (this.noseAngleRChange1 = '')
     },
     positionCodeSearch() {
       let positionCode = []
@@ -727,6 +798,66 @@
         }
       })
     },
+    chineseNameChange(chineseNameChange) {
+      this.chineseNameChange1 = chineseNameChange
+      this.model.groupCompanySign =
+        this.chineseNameChange1 +
+        this.toolModelChange1 +
+        this.bladeShapeChange1 +
+        this.bladeLengthChange1 +
+        this.cuttingEdgeCountChange1 +
+        this.noseAngleRChange1
+    },
+    toolModelChange(toolModelChange) {
+      this.toolModelChange1 = toolModelChange == '' ? '' : '-' + toolModelChange
+      this.model.groupCompanySign =
+        this.chineseNameChange1 +
+        this.toolModelChange1 +
+        this.bladeShapeChange1 +
+        this.bladeLengthChange1 +
+        this.cuttingEdgeCountChange1 +
+        this.noseAngleRChange1
+    },
+    bladeShapeChange(bladeShapeChange) {
+      this.bladeShapeChange1 = bladeShapeChange == '' ? '' : '-' + bladeShapeChange
+      this.model.groupCompanySign =
+        this.chineseNameChange1 +
+        this.toolModelChange1 +
+        this.bladeShapeChange1 +
+        this.bladeLengthChange1 +
+        this.cuttingEdgeCountChange1 +
+        this.noseAngleRChange1
+    },
+    bladeLengthChange(bladeLengthChange) {
+      this.bladeLengthChange1 = bladeLengthChange == '' ? '' : '-' + bladeLengthChange
+      this.model.groupCompanySign =
+        this.chineseNameChange1 +
+        this.toolModelChange1 +
+        this.bladeShapeChange1 +
+        this.bladeLengthChange1 +
+        this.cuttingEdgeCountChange1 +
+        this.noseAngleRChange1
+    },
+    cuttingEdgeCountChange(cuttingEdgeCountChange) {
+      this.cuttingEdgeCountChange1 = cuttingEdgeCountChange == '' ? '' : '-' + cuttingEdgeCountChange
+      this.model.groupCompanySign =
+        this.chineseNameChange1 +
+        this.toolModelChange1 +
+        this.bladeShapeChange1 +
+        this.bladeLengthChange1 +
+        this.cuttingEdgeCountChange1 +
+        this.noseAngleRChange1
+    },
+    noseAngleRChange(noseAngleRChange) {
+      this.noseAngleRChange1 = noseAngleRChange == '' ? '' : '-' + noseAngleRChange
+      this.model.groupCompanySign =
+        this.chineseNameChange1 +
+        this.toolModelChange1 +
+        this.bladeShapeChange1 +
+        this.bladeLengthChange1 +
+        this.cuttingEdgeCountChange1 +
+        this.noseAngleRChange1
+    },
   },
 }
 </script>

--
Gitblit v1.9.3