diff --git a/src/views/inm/mainso.vue b/src/views/inm/mainso.vue index b9b004b3..bf59197c 100644 --- a/src/views/inm/mainso.vue +++ b/src/views/inm/mainso.vue @@ -44,12 +44,13 @@ - - + + @@ -92,12 +93,26 @@ export default { materialsVisible:false, apiObjPrint:this.$API.cm.labelmat.fromMb, wmId:'', + state_:{ + 10:'合格', + 20:'不合格', + 30:'返修', + }, }; }, mounted() { this.getWarehouse(); }, methods: { + getType(type){ + if(type==10){ + return 'success' + }else if(type==20){ + return 'danger' + }else if(type==30){ + return 'warning' + } + }, getWarehouse() { this.$API.inm.warehouse.list.req({ page: 0 }).then((res) => { this.warehouseOptions = res; diff --git a/src/views/wpm_bx/handover_form.vue b/src/views/wpm_bx/handover_form.vue index fbd2b890..f631311a 100644 --- a/src/views/wpm_bx/handover_form.vue +++ b/src/views/wpm_bx/handover_form.vue @@ -113,6 +113,16 @@ + + + + + + + + + + @@ -182,7 +192,7 @@ v-model="listItem.count" controls-position="right" :min="0" - step="1" + :step="1" :max="listItem.count_cando" :disabled="mode==='show'" :step-strictly="true" @@ -258,6 +268,7 @@ export default { recive_user: null, recive_mgroup: null, handoverb:[], + new_batch:'' }, rules: { batch: [ @@ -321,6 +332,7 @@ export default { bwVisible:false, scanVisible:false, isSaveing: false, + change_batch:false, setFiltersVisible: false, }; }, @@ -364,7 +376,6 @@ export default { }, showbw(index){ this.bwIndex = index; - console.log('this.form.handoverb[index].handoverbw',this.form.handoverb[index].handoverbw); this.bwVisible = true; }, bwVisibleClose(){ @@ -390,6 +401,10 @@ export default { } }) that.getCkUserList();//废品库接收人 + }else if(that.type==30){ + this.getUserList3(); + }else{ + this.getUserList2(); } }); }, @@ -563,6 +578,9 @@ export default { }else{ this.getUserList2(); } + if(data.new_batch!==''&&data.new_batch!==undefined&&data.new_batch!==null){ + this.change_batch = true; + } }, //设置过滤项 setFilters(filters) { @@ -592,20 +610,21 @@ export default { //handoverb里有这个物料批次 if(arr.length>0){ //判断是否有wpr,若无将wpr放进去 - if(arr[0].handoverbw&&arr[0].handoverbw.length>0){ + if(that.form.handoverb[0].handoverbw&&that.form.handoverb[0].handoverbw.length>0){ let arr1 = []; - arr1 = arr[0].handoverbw.filter((item1) => { - item1.wpr = item1.id; + arr1 = that.form.handoverb[0].handoverbw.filter((item1) => { + return item1.wpr == res.id; }) if(arr1.length>0){ that.$message.error("该物料已存在"); + // console.log('0',that.form); }else{ let obj1 = {}; obj1.wpr = res.id; obj1.number = res.number; that.form.handoverb[indexs].count+=1; that.form.handoverb[indexs].handoverbw.push(obj1); - console.log('1',that.form); + // console.log('1',that.form); } }else{ that.form.handoverb[indexs].handoverbw = []; @@ -614,11 +633,10 @@ export default { obj1.number = res.number; that.form.handoverb[indexs].count=1; that.form.handoverb[indexs].handoverbw.push(obj1); - console.log('2',that.form); + // console.log('2',that.form); } }else{//handoverb里没有有这个物料批次 that.materialOptions.forEach((item) => { - console.log('item.id',item.id); if(item.id == res.wm){ let obj2 = {}; obj2.wm = item.id; @@ -631,7 +649,7 @@ export default { obj3.number = res.number; obj2.handoverbw.push(obj3); that.form.handoverb.push(obj2); - console.log('3',that.form); + // console.log('3',that.form); } }) } @@ -653,7 +671,7 @@ export default { obj.count_cando = item.count; obj.count = item.count; that.form.handoverb.push(obj); - console.log('4',that.form); + // console.log('4',that.form); } }) } diff --git a/src/views/wpm_bx/inm.vue b/src/views/wpm_bx/inm.vue index b7b7a4ec..a663f516 100644 --- a/src/views/wpm_bx/inm.vue +++ b/src/views/wpm_bx/inm.vue @@ -6,9 +6,9 @@ v-if="mgroupName=='清洗'" >领料 - 入库 + > --> 报废 @@ -112,7 +112,7 @@ >