From 73983f9d7f0e0dbc12b8f3ac3a39e4e15769db16 Mon Sep 17 00:00:00 2001
From: 86134 <aa>
Date: 星期二, 07 十一月 2023 17:30:59 +0800
Subject: [PATCH] 	modified:   src/api/quality/rawMaterial.js 	modified:   src/views/quality/processInspect/processInspect-form.vue

---
 src/views/quality/processInspect/processInspect-form.vue |   42 ++++++++++++++++++++++++++++++++++++++++--
 1 files changed, 40 insertions(+), 2 deletions(-)

diff --git a/src/views/quality/processInspect/processInspect-form.vue b/src/views/quality/processInspect/processInspect-form.vue
index d486d2d..c3adbb9 100644
--- a/src/views/quality/processInspect/processInspect-form.vue
+++ b/src/views/quality/processInspect/processInspect-form.vue
@@ -113,11 +113,26 @@
                                         <el-select style="width:100%" v-model="scope.row.eId" 
                                         v-if="scope.row.iname != null" filterable @change="updateDevice(scope.row,scope.$index)">
                                             <el-option v-for="(item,index) in deviceList" 
-                                            :key="index" :value="item.id" :label="item.number +'-'+ item.name"></el-option>
+                                            :key="index" :value="item.id" :label="item.code +'-'+ item.name"></el-option>
                                         </el-select>
                                     </div>
                                 </template>
                             </el-table-column>
+                            <el-table-column  label="妫�楠屾弿杩�"
+                                width="240" style="text-align: center;">
+                                <template slot-scope="scope">
+                                        <el-tooltip v-if="scope.row.iname!=null" :disabled="scope.row.eId != null" 
+                                        class="item" effect="dark" content="璇峰厛閫夋嫨璁惧锛�"
+                                            placement="top-start">
+                                            <el-input :disabled="scope.row.eId == null" v-model="scope.row.inote"
+                                         placeholder="璇疯緭鍏ユ楠屾弿杩�"></el-input>
+                                            <span v-if="resultVal != null && processInspectVo.id!=null" v-text="scope.row.inote"></span>
+                                        </el-tooltip>
+                                </template>
+                            </el-table-column>
+
+
+
                             <el-table-column label="缁撹" fixed="right" min-width="100">
                                 <template slot-scope="scope">
                                     <div v-if="scope.row.iname!=null">
@@ -218,6 +233,7 @@
             this.init()
         },
         methods: {
+            
             submitSave(){
                 let pro = 0
                 console.log(this.inspectionItems);
@@ -288,6 +304,7 @@
                 let id = this.processInspectVo.id
                 if(id != null){
                     queryById(id).then(res=>{
+                        console.log(res)
                         let result = res.data.data
                         this.processInspectVo.orderNumber = result.orderNumber
                         this.processInspectVo.materialCode = result.materialCode
@@ -300,6 +317,7 @@
                         result.children.forEach(item=>{
                             item.iid = Math.random()
                             if(item.children != undefined){
+                            
                                 item.children.forEach(obj=>{
                                     let arr = []
                                     if(obj.userName){
@@ -309,6 +327,9 @@
                                         arr = obj.inspectionValue.split(",")
                                     }
                                     obj.empiricalValueAddss = arr
+                                    if(obj.note){
+                                        snote=obj.inote
+                                    }
                                     if(arr.length > this.empiricalValueAdd){
                                         this.empiricalValueAdd = arr.length
                                     }
@@ -316,6 +337,7 @@
                             }
                         })
                         this.inspectionItems = result.children
+                        console.log(result.children)
                         this.inspectionResultForm = [{
                             materialCode: result.materialCode,
                             material: result.material,
@@ -330,15 +352,18 @@
             getDeviceList(){
                 selectDevice(null).then(res=>{
                     this.deviceList = res.data.data
+                    console.log(this.deviceList);
                 })
             },
             updateDevice(row,index){
+                console.log(row);
                 updateDeviceBypppId({equiomentId:row.eId,ppid:row.iId}).then(res=>{
                     this.inspectionItems.forEach(obj=>{
                         if(obj.children){
                             obj.children[index-1].inspectionValue = ''
                             obj.children[index-1].iresult = null
                             obj.children[index-1].empiricalValueAddss = []
+                             obj.children[index-1].inote=''
                         }
                     })
                 }).catch(error=>{
@@ -357,6 +382,8 @@
                 this.technologyList = sample.children
             },
             changeState(row, index) {
+                console.log(row)
+                
                 if (row.iid != null && row.iid != '') {
                     let str = ""
                     row.empiricalValueAddss.forEach(e => {
@@ -366,11 +393,19 @@
                     if (str === undefined || str === '' || str === null ) {
                         return
                     }
+
+                // if ( note === undefined || str === '' || str === null ) {
+                //         return
+                //     }
+                    
                     let obj = {
                         equiomentId: row.eId,
                         ppid: row.iid,
-                        inspectionValue: str
+                        inspectionValue: str,
+                        note:row.inote,
+                    
                     }
+                  
                     updateProcessInsProduct(obj).then(res=>{
                         if(res.data.code == 0){
                             this.$message.success("鏇存柊鎴愬姛")
@@ -394,6 +429,7 @@
                                 if(item.children != undefined){
                                     item.children.forEach(obj=>{
                                         obj.empiricalValueAddss = []
+                                        // obj.note=[];
                                     })
                                 }
                             })
@@ -410,8 +446,10 @@
                 chooseMater({
                         orderNumber: this.processInspectVo.orderNumber
                     }).then(res => {
+                    
                     if (res.data.data != null) {
                         this.optionsSamplename = res.data.data.children
+                        
                     } else {
                         this.$message({
                             message: '娌℃湁璇ヨ鍗曞彿锛�',

--
Gitblit v1.9.3