fix:返工日志检验表

This commit is contained in:
shijing 2025-12-29 13:40:51 +08:00
parent 33844efb7c
commit 473618307b
2 changed files with 29 additions and 16 deletions

View File

@ -339,6 +339,7 @@
:dept="deptId" :dept="deptId"
:mgroup="mgroup" :mgroup="mgroup"
:cutCount="cutCount" :cutCount="cutCount"
:material_in="materialIn"
:material_out="mlogItem.material_out" :material_out="mlogItem.material_out"
:mgroupName= "mlogItem.mgroup_name" :mgroupName= "mlogItem.mgroup_name"
:isSubmit="isSubmit" :isSubmit="isSubmit"
@ -585,7 +586,6 @@ export default {
let that = this; let that = this;
that.$API.wpm.mlog.item.req(that.mlogId).then((res) => { that.$API.wpm.mlog.item.req(that.mlogId).then((res) => {
that.mlogItem = res; that.mlogItem = res;
that.getcutCount(res.material_in);
that.isSubmit = res.submit_time==null?false:true; that.isSubmit = res.submit_time==null?false:true;
if(that.processType=='10'&&that.mlogItem.material_out_&&that.mlogItem.material_out_.tracking==20){ if(that.processType=='10'&&that.mlogItem.material_out_&&that.mlogItem.material_out_.tracking==20){
that.getMlogbw(); that.getMlogbw();
@ -608,16 +608,19 @@ export default {
that.fileList = [{name:res.test_file,url:res.test_file}]; that.fileList = [{name:res.test_file,url:res.test_file}];
that.form.test_file = res.test_file; that.form.test_file = res.test_file;
} }
that.materialIn = res.material_in; that.materialIn = res.material_in!==null?res.material_in:res.mlogb_full[0]?res.mlogb_full[0].material_in:null;
that.deptId = res.belong_dept; that.deptId = res.belong_dept;
that.checkTableShow = true; that.checkTableShow = true;
that.apiObjWm = that.$API.wpm.wmaterial.list; that.apiObjWm = that.$API.wpm.wmaterial.list;
that.$API.wpm.mlogb.list.req(that.paramsOut).then((res) => { that.$API.wpm.mlogb.list.req(that.paramsOut).then((res) => {
that.tableData2 = res; that.tableData2 = res;
}) })
that.$API.mtm.routepack.list.req({page:0,search:res.routepack_name}).then((res) => { if(!res.is_fix){
that.route_file = res[0].document_!==null?res[0].document_.path:null; that.getcutCount(res.material_in);
}) that.$API.mtm.routepack.list.req({page:0,search:res.routepack_name}).then((res) => {
that.route_file = res[0].document_!==null?res[0].document_.path:null;
})
}
}); });
}, },
getEquipment(){ getEquipment(){
@ -989,7 +992,7 @@ export default {
let that = this; let that = this;
that.printVisible = true; that.printVisible = true;
}, },
// //
printMaterial(row){ printMaterial(row){
let that = this; let that = this;
that.apiObjPrint.req({tid:row.id}).then((res) => { that.apiObjPrint.req({tid:row.id}).then((res) => {

View File

@ -382,25 +382,35 @@ export default {
watch: {}, watch: {},
mounted() { mounted() {
let that = this; let that = this;
that.route_code = that.$route.path.split("/")[2];
that.currentDate = that.$TOOL.dateFormat2(new Date());
if(that.processType=='20'){ if(that.processType=='20'){
that.canMultiple = true; that.canMultiple = true;
} }
if(that.qct!==''&&that.qct!==null){// if(that.qct!==''&&that.qct!==null){//
that.getdefects(); that.getdefects();
}else if(that.material_out!==''&&that.material_out!==null){// }else{
that.$API.qm.qct.getQct.req({ material: that.material_out,type:'out',tag:'process' }).then((res) => { if(that.route_code=='chengpingfanxiu'&&that.material_in!==''&&that.material_in!==null){//
that.qctId = res.id; that.$API.qm.qct.getQct.req({ material: that.material_in,type:'out',tag:'fix' }).then((res) => {
that.testdefectss(res); that.qctId = res.id;
}).catch(()=>{ that.testdefectss(res);
that.getList(); }).catch(()=>{
}) that.getList();
})
}else if(that.material_out!==''&&that.material_out!==null){//
that.$API.qm.qct.getQct.req({ material: that.material_out,type:'out',tag:'process' }).then((res) => {
that.qctId = res.id;
that.testdefectss(res);
}).catch(()=>{
that.getList();
})
}
} }
that.visible = true; that.visible = true;
setTimeout(() => { setTimeout(() => {
that.tableHeight = document.getElementById('mlogbwMain').clientHeight-20; that.tableHeight = document.getElementById('mlogbwMain').clientHeight-20;
},500) },500)
that.route_code = that.$route.path.split("/")[2];
that.currentDate = that.$TOOL.dateFormat2(new Date());
}, },
methods: { methods: {
refreshfun(){ refreshfun(){
@ -707,7 +717,7 @@ export default {
let that = this; let that = this;
that.printVisible = true; that.printVisible = true;
}, },
// //
printMaterial(row){ printMaterial(row){
let that = this; let that = this;
that.apiObjPrint.req({tid:row.id}).then((res) => { that.apiObjPrint.req({tid:row.id}).then((res) => {