From 1e9c7a02ec2b8caf7dda6000d7f0f79849df6b45 Mon Sep 17 00:00:00 2001
From: 朱佳吉 <1527963051@qq.com>
Date: 星期四, 09 五月 2024 14:15:25 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 src/components/do/b1-ins-order/add.vue |   32 ++++++++++++++++++++------------
 1 files changed, 20 insertions(+), 12 deletions(-)

diff --git a/src/components/do/b1-ins-order/add.vue b/src/components/do/b1-ins-order/add.vue
index 87de2ad..f5b4a48 100644
--- a/src/components/do/b1-ins-order/add.vue
+++ b/src/components/do/b1-ins-order/add.vue
@@ -270,10 +270,17 @@
         <el-table-column prop="model" label="鏍峰搧鍨嬪彿" align="center" min-width="100">
           <template slot-scope="scope">
             <el-select v-model="scope.row.model" filterable allow-create default-first-option placeholder="鏍峰搧鍨嬪彿"
-              size="small" @change="handleChangeModel" :disabled="active>1">
+              size="small" @change="handleChangeModel" :disabled="active>1" style="width: 100%;" disabled>
               <el-option v-for="item in models" :key="item.value" :label="item.label" :value="item.value">
               </el-option>
             </el-select>
+          </template>
+        </el-table-column>
+        <el-table-column prop="modelNum" label="鍨嬪彿鍙傛暟" width="130" align="center" v-if="!(active>1)">
+          <template slot-scope="scope">
+            <el-input size="small" v-model="scope.row.modelNum" clearable placeholder="闈炲繀濉�"
+              @keyup.enter.native="methodChange(scope.row.standardMethodListId, scope.row)"
+              @clear="methodChange(scope.row.standardMethodListId, scope.row)"></el-input>
           </template>
         </el-table-column>
         <el-table-column prop="standardMethodListId" label="妫�楠屾爣鍑�" align="center" min-width="100">
@@ -286,13 +293,13 @@
             </el-select>
           </template>
         </el-table-column>
-        <el-table-column prop="unit" label="鍗曚綅" align="center" min-width="100">
+        <!-- <el-table-column prop="unit" label="鍗曚綅" align="center" min-width="100">
           <template slot-scope="scope">
             <el-select v-model="scope.row.unit" clearable size="small" style="width: 100%;" :disabled="active>1">
               <el-option v-for="(a, i) in units" :key="i" :label="a.label" :value="a.value"></el-option>
             </el-select>
           </template>
-        </el-table-column>
+        </el-table-column> -->
         <!-- <el-table-column prop="isLeave" label="鏄惁鐣欐牱" align="center" min-width="100">
           <template slot-scope="scope">
             <el-select v-model="scope.row.isLeave" size="small" :disabled="active>1">
@@ -334,7 +341,7 @@
         <el-table-column prop="unit" label="璁¢噺鍗曚綅" width="100" show-overflow-tooltip></el-table-column>
         <el-table-column prop="price" label="鍗曚环" width="100" show-overflow-tooltip></el-table-column>
         <el-table-column prop="manDay" label="棰勮鏃堕棿(澶�)" width="120" show-overflow-tooltip></el-table-column>
-        <el-table-column prop="manHourGroup" label="宸ユ椂鍒嗙粍" width="100" show-overflow-tooltip></el-table-column>
+        <el-table-column prop="manHour" label="宸ユ椂绯绘暟" width="100" show-overflow-tooltip></el-table-column>
         <!-- <el-table-column prop="deviceGroup" label="璁惧缁�" width="120" show-overflow-tooltip></el-table-column> -->
         <el-table-column prop="section" label="鍖洪棿" width="120" show-overflow-tooltip></el-table-column>
         <el-table-column prop="ask" label="瑕佹眰鍊�" min-width="220px">
@@ -370,7 +377,7 @@
             <el-row>
               <el-col :span="24">
                 <span><i
-                    :class="`node_i ${data.children != undefined ? 'el-icon-folder-opened' : 'el-icon-tickets'}`"></i>
+                    :class="`node_i ${data.children != undefined ? (data.code==='[1]'?'el-icon-folder-opened':'el-icon-folder') : 'el-icon-tickets'}`"></i>
                   {{ data.code }} {{ data.label }}</span>
               </el-col>
             </el-row>
@@ -562,6 +569,7 @@
           sampleType: null,
           sample: null,
           model: null,
+          modelNum: null,
           sampleNum: 1,
           isLeave: 0,
           unit: null
@@ -718,13 +726,14 @@
           this.$message.error('璇疯緭鍏ユ牱鍝佸瀷鍙�')
         } else if (!this.sampleList.every(m => m.standardMethodListId)) {
           this.$message.error('璇烽�夋嫨妫�楠屾爣鍑�')
-        } else if (!this.sampleList.every(m => m.unit)) {
-          this.$message.error('璇疯緭鍏ユ牱鍝佺殑鍗曚綅')
         } else {
           this.saveLoad = true
           this.$axios.post(this.$api.insOrder.addInsOrder, {
             insOrder: this.addObj,
-            list: JSON.stringify(this.sampleList)
+            list: JSON.stringify(this.sampleList.map(a=>{
+              a.model = a.model + ((a.modelNum==null||a.modelNum==''||a.modelNum=='null')?'':('-'+a.modelNum))
+              return a
+            }))
           }, {
             headers: {
               'Content-Type': 'application/json'
@@ -849,9 +858,7 @@
         this.$axios.get(this.$api.standardTree.selectStandardTreeList).then(res => {
           this.list = res.data
           this.list.forEach(a => {
-            a.children.forEach(b => {
-              this.expandedKeys.push(b.label)
-            })
+            this.expandedKeys.push(a.label)
           })
         })
       },
@@ -1116,9 +1123,10 @@
         })
       },
       methodChange(val, row) {
+        if(val===null||val==='')return
         this.getProductLoad = true
         this.$axios.post(this.$api.standardTree.selectStandardProductList, {
-          model: this.addObj.model,
+          model: this.addObj.model + '-' + row.modelNum,
           standardMethodListId: val
         }, {
           headers: {

--
Gitblit v1.9.3