|
@@ -54,7 +54,18 @@
|
|
<el-table-column align="center" label="班级" prop="name" sortable></el-table-column>
|
|
<el-table-column align="center" label="班级" prop="name" sortable></el-table-column>
|
|
<el-table-column align="center" label="科目" prop="subname" sortable></el-table-column>
|
|
<el-table-column align="center" label="科目" prop="subname" sortable></el-table-column>
|
|
<el-table-column align="center" label="日期" prop="day" sortable></el-table-column>
|
|
<el-table-column align="center" label="日期" prop="day" sortable></el-table-column>
|
|
- <el-table-column align="center" label="已安排授课教师(点击修改)" prop="teaname"></el-table-column>
|
|
|
|
|
|
+ <el-table-column align="center" label="已安排授课教师(点击修改)" prop="teaname">
|
|
|
|
+ <template v-slot="{ row }">
|
|
|
|
+ <el-row>
|
|
|
|
+ <el-col :span="24">
|
|
|
|
+ {{ row.teaname }}
|
|
|
|
+ <el-link v-if="getNoticeStatus(row)" :type="getNoticeStatus(row) === '0' ? 'warning' : 'success'">
|
|
|
|
+ {{ getNoticeStatus(row) === '0' ? '未确认' : '已确认' }}
|
|
|
|
+ </el-link>
|
|
|
|
+ </el-col>
|
|
|
|
+ </el-row>
|
|
|
|
+ </template>
|
|
|
|
+ </el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
|
|
|
|
<el-dialog title="选择教师" width="30%" :visible.sync="dialog" center :destroy-on-close="true" @close="toClose">
|
|
<el-dialog title="选择教师" width="30%" :visible.sync="dialog" center :destroy-on-close="true" @close="toClose">
|
|
@@ -84,6 +95,17 @@
|
|
</el-col>
|
|
</el-col>
|
|
</el-checkbox-group>
|
|
</el-checkbox-group>
|
|
</el-row>
|
|
</el-row>
|
|
|
|
+ <el-row style="text-align:center" class="msgrow">
|
|
|
|
+ <el-col :span="24">请选择班级类型</el-col>
|
|
|
|
+ <el-radio-group v-model="ctselect">
|
|
|
|
+ <el-col :span="8">
|
|
|
|
+ <el-radio border size="small" :label="undefined">全部</el-radio>
|
|
|
|
+ </el-col>
|
|
|
|
+ <el-col :span="8" v-for="(i, index) in ctList" :key="index">
|
|
|
|
+ <el-radio :label="i.code" border size="small">{{ i.name }}</el-radio>
|
|
|
|
+ </el-col>
|
|
|
|
+ </el-radio-group>
|
|
|
|
+ </el-row>
|
|
<span slot="footer" class="dialog-footer">
|
|
<span slot="footer" class="dialog-footer">
|
|
<el-button @click="msgDialog = false">取 消</el-button>
|
|
<el-button @click="msgDialog = false">取 消</el-button>
|
|
<el-button type="primary" @click="toSendMsg">确 定</el-button>
|
|
<el-button type="primary" @click="toSendMsg">确 定</el-button>
|
|
@@ -117,6 +139,7 @@ const { mapActions: subject } = createNamespacedHelpers('subject');
|
|
const { mapActions: ct } = createNamespacedHelpers('classtype');
|
|
const { mapActions: ct } = createNamespacedHelpers('classtype');
|
|
const { mapActions: teacher } = createNamespacedHelpers('teacher');
|
|
const { mapActions: teacher } = createNamespacedHelpers('teacher');
|
|
const { mapActions: teaplan } = createNamespacedHelpers('teaPlan');
|
|
const { mapActions: teaplan } = createNamespacedHelpers('teaPlan');
|
|
|
|
+const { mapActions: notice } = createNamespacedHelpers('notice');
|
|
export default {
|
|
export default {
|
|
name: 'teacher-lesson',
|
|
name: 'teacher-lesson',
|
|
props: {},
|
|
props: {},
|
|
@@ -133,6 +156,7 @@ export default {
|
|
},
|
|
},
|
|
msgForm: [],
|
|
msgForm: [],
|
|
conForm: [],
|
|
conForm: [],
|
|
|
|
+ ctselect: undefined,
|
|
teacherList: [],
|
|
teacherList: [],
|
|
plan: {},
|
|
plan: {},
|
|
options: null,
|
|
options: null,
|
|
@@ -142,10 +166,12 @@ export default {
|
|
termList: [],
|
|
termList: [],
|
|
applyList: [],
|
|
applyList: [],
|
|
info: {},
|
|
info: {},
|
|
|
|
+ noticeList: {},
|
|
};
|
|
};
|
|
},
|
|
},
|
|
created() {},
|
|
created() {},
|
|
methods: {
|
|
methods: {
|
|
|
|
+ ...notice({ getNoticeList: 'query' }),
|
|
...teaplan({ getApplyTeacher: 'query', toArrrangeTeacher: 'arrangeTeacher', sendMsg: 'sendMsg', confirmPlan: 'confirmPlan' }),
|
|
...teaplan({ getApplyTeacher: 'query', toArrrangeTeacher: 'arrangeTeacher', sendMsg: 'sendMsg', confirmPlan: 'confirmPlan' }),
|
|
...ct({ getCt: 'query' }),
|
|
...ct({ getCt: 'query' }),
|
|
...subject({ getSubject: 'query' }),
|
|
...subject({ getSubject: 'query' }),
|
|
@@ -227,7 +253,8 @@ export default {
|
|
async toSendMsg() {
|
|
async toSendMsg() {
|
|
const { planid } = this.options;
|
|
const { planid } = this.options;
|
|
const dup = _.cloneDeep(this.msgForm);
|
|
const dup = _.cloneDeep(this.msgForm);
|
|
- const res = await this.sendMsg({ planid, ids: dup });
|
|
|
|
|
|
+ console.log(this.ctselect);
|
|
|
|
+ const res = await this.sendMsg({ planid, ids: dup, classtype: this.ctselect });
|
|
this.toClose();
|
|
this.toClose();
|
|
},
|
|
},
|
|
// 确认指定期安排
|
|
// 确认指定期安排
|
|
@@ -247,6 +274,7 @@ export default {
|
|
await this.getCtList();
|
|
await this.getCtList();
|
|
await this.getSubjectList();
|
|
await this.getSubjectList();
|
|
await this.getTeacherList();
|
|
await this.getTeacherList();
|
|
|
|
+ await this.getNotice();
|
|
}
|
|
}
|
|
await this.getTrain();
|
|
await this.getTrain();
|
|
this.setData();
|
|
this.setData();
|
|
@@ -360,6 +388,7 @@ export default {
|
|
selectTeacher(teaid) {
|
|
selectTeacher(teaid) {
|
|
let r = this.applyList.find(f => f.teacherid == teaid);
|
|
let r = this.applyList.find(f => f.teacherid == teaid);
|
|
if (r) this.info.teaname = r.teaname;
|
|
if (r) this.info.teaname = r.teaname;
|
|
|
|
+ else this.$set(this, `info`, _.omit(this.info, ['teaid', 'teaname']));
|
|
},
|
|
},
|
|
async toArrrange() {
|
|
async toArrrange() {
|
|
let msg = this.$message({ message: '正在处理,请稍后...', duration: 0 });
|
|
let msg = this.$message({ message: '正在处理,请稍后...', duration: 0 });
|
|
@@ -370,12 +399,32 @@ export default {
|
|
this.getInfo('reload');
|
|
this.getInfo('reload');
|
|
}
|
|
}
|
|
},
|
|
},
|
|
|
|
+ async getNotice() {
|
|
|
|
+ const { planid } = this.defaultOption;
|
|
|
|
+ const res = await this.getNoticeList({ planid, type: '6' });
|
|
|
|
+ if (this.$checkRes(res)) this.$set(this, `noticeList`, res.data);
|
|
|
|
+ },
|
|
toSendDialog() {
|
|
toSendDialog() {
|
|
this.msgDialog = true;
|
|
this.msgDialog = true;
|
|
},
|
|
},
|
|
toConDialog() {
|
|
toConDialog() {
|
|
this.conDialog = true;
|
|
this.conDialog = true;
|
|
},
|
|
},
|
|
|
|
+ getNoticeStatus(row) {
|
|
|
|
+ const { teaid } = row;
|
|
|
|
+ if (!teaid) return;
|
|
|
|
+ const res = this.noticeList.find(f => f.termid == row.termid && f.classid == row.classid);
|
|
|
|
+ if (res) {
|
|
|
|
+ const { notified } = res;
|
|
|
|
+ if (_.isArray(notified)) {
|
|
|
|
+ const r = notified.find(f => f.notifiedid === teaid);
|
|
|
|
+ if (r) {
|
|
|
|
+ console.log(r);
|
|
|
|
+ return r.status;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ },
|
|
},
|
|
},
|
|
watch: {
|
|
watch: {
|
|
defaultOption: {
|
|
defaultOption: {
|
|
@@ -391,12 +440,12 @@ export default {
|
|
if (nplanid && !_.isEqual(nplanid, oplanid)) {
|
|
if (nplanid && !_.isEqual(nplanid, oplanid)) {
|
|
this.getInfo();
|
|
this.getInfo();
|
|
}
|
|
}
|
|
- let ntermid = _.get(val, 'termid');
|
|
|
|
- let otermid = _.get(this.options, 'termid');
|
|
|
|
- if (ntermid && !_.isEqual(ntermid, otermid)) {
|
|
|
|
- this.$set(this, `options`, _.cloneDeep(val));
|
|
|
|
- this.getInfo();
|
|
|
|
- }
|
|
|
|
|
|
+ // let ntermid = _.get(val, 'termid');
|
|
|
|
+ // let otermid = _.get(this.options, 'termid');
|
|
|
|
+ // if (ntermid && !_.isEqual(ntermid, otermid)) {
|
|
|
|
+ // this.$set(this, `options`, _.cloneDeep(val));
|
|
|
|
+ // this.getInfo();
|
|
|
|
+ // }
|
|
}
|
|
}
|
|
},
|
|
},
|
|
},
|
|
},
|