|
@@ -8,6 +8,8 @@
|
|
<el-col :span="24" class="main">
|
|
<el-col :span="24" class="main">
|
|
<headStuList
|
|
<headStuList
|
|
:headStuList="headStuList"
|
|
:headStuList="headStuList"
|
|
|
|
+ :groupStuList="groupStuList"
|
|
|
|
+ :noGroupStuList="noGroupStuList"
|
|
:assignShow="assignShow"
|
|
:assignShow="assignShow"
|
|
:assignForm="assignForm"
|
|
:assignForm="assignForm"
|
|
:job_list="job_list"
|
|
:job_list="job_list"
|
|
@@ -39,6 +41,8 @@ export default {
|
|
},
|
|
},
|
|
data: () => ({
|
|
data: () => ({
|
|
headStuList: [],
|
|
headStuList: [],
|
|
|
|
+ noGroupStuList: [],
|
|
|
|
+ groupStuList: [],
|
|
assignShow: false,
|
|
assignShow: false,
|
|
assignForm: {},
|
|
assignForm: {},
|
|
job_list: [],
|
|
job_list: [],
|
|
@@ -115,14 +119,11 @@ export default {
|
|
const groups = await this.groupQuery({ classid });
|
|
const groups = await this.groupQuery({ classid });
|
|
//班级所有进组的学生id
|
|
//班级所有进组的学生id
|
|
let groupstuids = _.map(_.flattenDeep(_.map(groups.data, 'students')), 'stuid');
|
|
let groupstuids = _.map(_.flattenDeep(_.map(groups.data, 'students')), 'stuid');
|
|
- const a = _.differenceBy(res.data, groupstuids, function(x, y) {
|
|
|
|
- console.log(x.id != y);
|
|
|
|
- return x.id != y;
|
|
|
|
- });
|
|
|
|
- console.log(a);
|
|
|
|
-
|
|
|
|
|
|
+ let noGroupStuList = res.data.filter(f => !groupstuids.includes(f.id));
|
|
if (this.$checkRes(res)) {
|
|
if (this.$checkRes(res)) {
|
|
|
|
+ this.$set(this, `groupStuList`, groups.data);
|
|
this.$set(this, `headStuList`, res.data);
|
|
this.$set(this, `headStuList`, res.data);
|
|
|
|
+ this.$set(this, `noGroupStuList`, noGroupStuList);
|
|
}
|
|
}
|
|
},
|
|
},
|
|
//点击派遣
|
|
//点击派遣
|
|
@@ -161,7 +162,6 @@ export default {
|
|
}
|
|
}
|
|
this.assignShow = true;
|
|
this.assignShow = true;
|
|
const res = await this.fet(id);
|
|
const res = await this.fet(id);
|
|
- console.log(res.data);
|
|
|
|
this.$set(this, `assignForm`, res.data);
|
|
this.$set(this, `assignForm`, res.data);
|
|
},
|
|
},
|
|
//指派职务
|
|
//指派职务
|