fix:玻纤交接调整

This commit is contained in:
shijing 2025-08-06 16:50:12 +08:00
parent e3c085beec
commit 2503653d28
1 changed files with 32 additions and 32 deletions

View File

@ -358,8 +358,8 @@ export default {
if(that.type==20||that.type==50){ if(that.type==20||that.type==50){
that.form.recive_mgroup = that.mgroupId; that.form.recive_mgroup = that.mgroupId;
} }
// type=10 // type=10
// type=20 // type=20
// type=30 // type=30
// type=40 // type=40
// type=50 // type=50
@ -371,23 +371,19 @@ export default {
that.getUserList(); that.getUserList();
} }
// //
if((that.type==20&&that.mgroupName!=='废品库')||that.type==40){ if(that.type==10||that.type==50){//
console.log('that.mgroupName',that.mgroupName);
if(that.mgroupName=='成品内外初检'||that.mgroupName=='成品内质复检'||that.mgroupName=='成品性能检测'||that.mgroupName=='成品尺寸检测'||that.mgroupName=='成品外观复检一'||that.mgroupName=='成品外观复检二'){
that.getMaterialOkFangong();
}else{
that.getMaterialNotok();
}
}else if(that.type==20&&that.mgroupName=='废品库'){
that.getMaterialFP();
}else{
that.getMaterial(); that.getMaterial();
}else if(that.type==20){//
if(that.mgroupName=='废品库'){
that.getMaterialFP();
}else{
that.getMaterialOkFangong();
}
}else if(that.type==40){//
that.getMaterialNotok();
}else if(that.type==60){
} }
if(that.type==30){
that.getDeptOptions();
}
that.getMgroupOptions(); that.getMgroupOptions();
}, },
methods: { methods: {
@ -436,8 +432,8 @@ export default {
let that = this; let that = this;
var req = { var req = {
page: 0, page: 0,
// state:10, tag:'done',
mgroupx:that.mgroupId mgroup:that.mgroupId
}; };
if(that.type!==50){ if(that.type!==50){
req.state = 10; req.state = 10;
@ -454,9 +450,9 @@ export default {
let that = this; let that = this;
that.materialOptions = []; that.materialOptions = [];
var req = { var req = {
mgroupx: that.mgroupId, mgroup: that.mgroupId,
page: 0, page: 0,
state__in:'20,34' state:20
}; };
this.$API.wpm.wmaterial.list.req(req).then((res) => { this.$API.wpm.wmaterial.list.req(req).then((res) => {
that.materialOptions = res.filter(item=>{ that.materialOptions = res.filter(item=>{
@ -479,12 +475,14 @@ export default {
}) })
}); });
}, },
//
getMaterialOkFangong(){ getMaterialOkFangong(){
let that = this; let that = this;
that.materialOptions = []; that.materialOptions = [];
var obj = { var obj = {
page: 0, page: 0,
tag:'done', tag:'done',
state__in:'20,34',
mgroup: that.mgroupId, mgroup: that.mgroupId,
}; };
that.$API.wpm.wmaterial.list.req(obj).then((res) => { that.$API.wpm.wmaterial.list.req(obj).then((res) => {
@ -589,17 +587,19 @@ export default {
return that.selectItems.indexOf(item.id)>-1; return that.selectItems.indexOf(item.id)>-1;
}); });
let materialId = data[0].material; let materialId = data[0].material;
let params = { if(that.type==50){}else{
material: materialId, let params = {
type: that.type, material: materialId,
}; type: that.type,
that.$API.wpm.handover.mgroups.req(params).then((res) => { };
that.mgroupOptions = res; that.$API.wpm.handover.mgroups.req(params).then((res) => {
if(res.length==1){ that.mgroupOptions = res;
that.form.recive_mgroup = res[0].id; if(res.length==1){
that.getUserList2(); that.form.recive_mgroup = res[0].id;
} that.getUserList2();
}) }
})
}
data.forEach((item,index)=>{ data.forEach((item,index)=>{
item.wm = item.id; item.wm = item.id;
item.count = item.count_canhandover; item.count = item.count_canhandover;