diff --git a/src/views/inm/good_mio.vue b/src/views/inm/good_mio.vue index d92829ee..d1043bda 100644 --- a/src/views/inm/good_mio.vue +++ b/src/views/inm/good_mio.vue @@ -113,7 +113,7 @@ v-auth="'mio.submit'" v-if="scope.row.state == 10" > - 接收 + 接收 提交 - + - + + @@ -39,13 +48,13 @@ @@ -69,7 +78,9 @@ export default { mioitem__material__type:30, ftest__isnull:0, mioitem__mio__state:20, - } + }, + dataTotal:0, + apiObj:this.$API.inm.mioitemw.list, }; }, diff --git a/src/views/statistics/bxerp/workerTimesRY.vue b/src/views/statistics/bxerp/workerTimesRY.vue index b8395648..25ab6102 100644 --- a/src/views/statistics/bxerp/workerTimesRY.vue +++ b/src/views/statistics/bxerp/workerTimesRY.vue @@ -47,6 +47,10 @@ > + + + + @@ -58,10 +62,6 @@ - - - - diff --git a/src/views/wpm/mlog6_form.vue b/src/views/wpm/mlog6_form.vue index 99f7d990..0dfee290 100644 --- a/src/views/wpm/mlog6_form.vue +++ b/src/views/wpm/mlog6_form.vue @@ -729,7 +729,7 @@ export default { countUseChange(){ if(this.form.count_real>this.form.count_use){ this.form.count_real = this.form.count_use; - this.count_ok = this.form.count_real - this.form.count_notok; + this.form.count_ok = this.form.count_use - this.form.count_notok; } }, countNotOkSun() { diff --git a/src/views/wpm_bx/handover_form.vue b/src/views/wpm_bx/handover_form.vue index 1df7de81..86181b02 100644 --- a/src/views/wpm_bx/handover_form.vue +++ b/src/views/wpm_bx/handover_form.vue @@ -160,7 +160,7 @@ - + - + { + console.log('that.type',that.type,'that.mtype',that.mtype) + if(that.type==20||that.type==50||(that.type==10&&that.mtype==30)||(that.mtype==30&&that.new_wm!=='')){ + that.form.recive_mgroup = that.mgroupId; + } + }) // type=10 正常交接 物料都可交接,接收工段有限制 // type=20 返工交接 不合格品交接,接收工段为该工艺流程中的工段 // type=30 物料检验 合格品交接,检验部接收 @@ -755,9 +759,6 @@ export default { let that = this; that.$refs.dialogForm.validate(async (valid) => { if (valid) { - if(that.mtype==30){ - that.form.recive_mgroup = that.form.send_mgroup; - } that.form.mtype=that.mtype; if(that.route_code=='shangpaipingmo'){ that.form.handoverb.forEach(item=>{ @@ -771,7 +772,7 @@ export default { }) } //合批、分批、报废,这三个交接操作直接创建并提交 - if(that.mtype==20||that.mtype==30||that.type==40){ + if(that.mtype==20||(that.mtype==30&&that.type==50&&that.new_wm!=='')||(that.mtype==30&&that.type==10)||that.type==40){ that.$API.wpm.handover.createsubmit.req(that.form).then((res) => { that.isSaveing = false; that.$emit("success"); diff --git a/src/views/wpm_bx/handover_form2.vue b/src/views/wpm_bx/handover_form2.vue index ca2cd6cf..3f25fe2e 100644 --- a/src/views/wpm_bx/handover_form2.vue +++ b/src/views/wpm_bx/handover_form2.vue @@ -30,7 +30,7 @@ - 选择物料: + 选择物料: 数量:{{ listItem.count }} - -
- {{ item2.number }} - + +
+
+ {{ item2.number }} + +
+
+ {{ item2.number }} +
-
+ + + + + + @@ -141,6 +152,7 @@ export default { trigger: "blur", }, }, + route_code:"", batchOrign:{}, wprOptions: [], materialOptions: [], @@ -152,6 +164,9 @@ export default { }, mounted() { let that = this; + let paths = that.$route.path; + let arr = paths.split("/"); + that.route_code = arr[2]; that.form.type = that.type; that.form.handle_date = that.form.send_date = that.$TOOL.dateFormat2(new Date()); that.form.send_mgroup = that.form.recive_mgroup = that.mgroupId; @@ -162,6 +177,9 @@ export default { getWpr(id){ let that = this; that.$API.wpm.wpr.list.req({page:0,wm:id}).then((res) => { + res.forEach(item=>{ + item.checked = false; + }) that.wprOptions = res; }); }, @@ -218,34 +236,37 @@ export default { if(arrs.length>1){ that.form.handoverb[index].wpr = ''; arrs.forEach(arr=>{ - that.wprOptions.forEach(item=>{ + let obj = {}; + obj.number = arr; + let options = that.wprOptions.filter(item=>{return item.number.indexOf(arr) > -1&&!item.disabled}); + if(options.length>0){ + obj.wpr = options[0].id; + barchArrs.push(arr); + } + that.form.handoverb[index].handoverbw.push(obj); + that.wprOptions.forEach(item=>{ if(item.number.indexOf(arr) > -1&&!item.disabled){ item.disabled = true; - let obj = {}; - obj.number = item.number; - obj.wpr = item.id; - barchArrs.push(arr); - that.form.handoverb[index].handoverbw.push(obj); - that.form.handoverb[index].count = that.form.handoverb[index].handoverbw.length; } }) + }) + that.form.handoverb[index].count = barchArrs.length; //如果arrs里有不是这个批次的wpr,提示错误 let diff = arrs.filter(item => !barchArrs.includes(item)); that.diff = diff; - console.log('diff',diff) if(diff.length>0){ that.$message.warning("物料"+diff.join(",")+"不在该批次中"); - // that.$confirm("物料"+diff.join(",")+"不在该批次中", "提示", {type: "warning",}).then(() => {}); } }else{ //放入对应的行中的handoverb中,并且在列表中disabled that.wprOptions.forEach(item=>{ - if(item.number.indexOf(arr) > -1){ + if(item.number.indexOf(number) > -1){ if(item.disabled){ that.$message.error("该物料已被分配"); that.form.handoverb[index].wpr = ''; }else{ + item.checked = true; item.disabled = true; let obj = {}; obj.number = item.number; @@ -295,6 +316,21 @@ export default { } that.form.handoverb.splice(index,1); }, + handleChange(index){ + let that = this; + that.form.handoverb[index].handoverbw = []; + let trueCount = this.wprOptions.filter(item => item.checked === true).length; + that.form.handoverb[index].count =trueCount; + this.wprOptions.forEach(item=>{ + if(item.checked){ + let obj = {}; + obj.number = item.number; + obj.wpr = item.id; + item.disabled = true; + that.form.handoverb[index].handoverbw.push(obj); + } + }) + }, //提交 submit() { let that = this; @@ -303,6 +339,7 @@ export default { let total = 0; if(this.form.handoverb.length>0){ this.form.handoverb.forEach(item=>{ + item.handoverbw = item.handoverbw.filter(item=>{ return item.wpr&&item.wpr!==''&&item.wpr!==null&&item.wpr!==undefined}) total += item.count; }) } diff --git a/src/views/wpm_bx/inmIn.vue b/src/views/wpm_bx/inmIn.vue index b6e305be..43ec2af5 100644 --- a/src/views/wpm_bx/inmIn.vue +++ b/src/views/wpm_bx/inmIn.vue @@ -93,7 +93,7 @@ min-width="150" > diff --git a/src/views/wpm_gx/handover.vue b/src/views/wpm_gx/handover.vue index 1a3c059f..b5211ce5 100644 --- a/src/views/wpm_gx/handover.vue +++ b/src/views/wpm_gx/handover.vue @@ -101,20 +101,15 @@
- + - + -