fix:玻纤交接人员筛选修正

This commit is contained in:
shijing 2025-02-19 09:12:42 +08:00
parent d0509a8a4a
commit 64e6e2edb7
1 changed files with 23 additions and 19 deletions

View File

@ -359,10 +359,14 @@ export default {
let day = date.getDate(); let day = date.getDate();
that.form.handle_date = year + "-" + month + "-" + day; that.form.handle_date = year + "-" + month + "-" + day;
that.form.send_mgroup = that.mgroupId; that.form.send_mgroup = that.mgroupId;
// type=10
// type=20
// type=30
// type=40
// type=50
///
if(that.mgroupName=="size"||that.mgroupName=="facade"){// if(that.mgroupName=="size"||that.mgroupName=="facade"){//
that.$API.system.user.list that.$API.system.user.list.req({ page: 0, posts__code__contains: "check" }).then((res) => {
.req({ page: 0, posts__code__contains: "check" })
.then((res) => {
that.userList = res; that.userList = res;
}); });
}else if(that.type==20&&that.mgroupName=='废品库'){// }else if(that.type==20&&that.mgroupName=='废品库'){//
@ -371,6 +375,7 @@ export default {
that.deptID = that.$TOOL.data.get('gx_deptID'); that.deptID = that.$TOOL.data.get('gx_deptID');
that.getUserList(); that.getUserList();
} }
//
if((that.type==20&&that.mgroupName!=='废品库')||that.type==40){ if((that.type==20&&that.mgroupName!=='废品库')||that.type==40){
that.getMaterialNotok(); that.getMaterialNotok();
}else if(that.type==20&&that.mgroupName=='废品库'){ }else if(that.type==20&&that.mgroupName=='废品库'){
@ -378,7 +383,10 @@ export default {
}else{ }else{
that.getMaterial(); that.getMaterial();
} }
if(that.type==30){
that.getDeptOptions(); that.getDeptOptions();
}
that.getMgroupOptions(); that.getMgroupOptions();
}, },
methods: { methods: {
@ -395,9 +403,7 @@ export default {
}, },
// //
getDeptOptions() { getDeptOptions() {
this.$API.system.dept.list this.$API.system.dept.list.req({ page: 0, type: "dept" }).then((res) => {
.req({ page: 0, type: "dept" })
.then((res) => {
this.deptOptions = res; this.deptOptions = res;
}); });
}, },
@ -486,14 +492,14 @@ export default {
let that = this; let that = this;
if(that.mode=="add"){ if(that.mode=="add"){
that.$API.mtm.mgroup.item.req(that.form.recive_mgroup).then((res) => { that.$API.mtm.mgroup.item.req(that.form.recive_mgroup).then((res) => {
this.$API.system.user.list.req({ belong_dept: res.belong_dept, page: 0 }).then((res) => { this.$API.system.user.list.req({ depts: res.belong_dept, page: 0 }).then((res) => {
that.userList2 = res; that.userList2 = res;
}); });
}) })
}else{ }else{
this.mgroupOptions.forEach(item => { this.mgroupOptions.forEach(item => {
if(item.id==that.form.recive_mgroup){ if(item.id==that.form.recive_mgroup){
this.$API.system.user.list.req({ belong_dept: item.belong_dept, page: 0 }).then((res) => { this.$API.system.user.list.req({ depts: item.belong_dept, page: 0 }).then((res) => {
that.userList2 = res; that.userList2 = res;
}); });
} }
@ -503,9 +509,7 @@ export default {
// //
getUserList3() { getUserList3() {
let that = this; let that = this;
this.$API.system.user.list this.$API.system.user.list.req({ depts: that.form.recive_dept, page: 0 }).then((res) => {
.req({ depts: that.form.recive_dept, page: 0 })
.then((res) => {
that.userList2 = res; that.userList2 = res;
}); });
}, },
@ -621,7 +625,7 @@ export default {
if(data.type==30){ if(data.type==30){
this.getUserList3(); this.getUserList3();
}else{ }else{
this.$API.system.user.list.req({ belong_dept: data.recive_dept, page: 0 }).then((res) => { this.$API.system.user.list.req({ depts: data.recive_dept, page: 0 }).then((res) => {
that.userList2 = res; that.userList2 = res;
}); });
setTimeout(() => { setTimeout(() => {