|
@@ -14,12 +14,28 @@
|
|
|
</el-row>
|
|
|
<el-row type="flex" v-loading="loading" style="min-height:500px">
|
|
|
<el-col :span="8" v-for="(i, index) in list" :key="index">
|
|
|
- <lesson-table type="usual" :data="i" :batch="`${index + 1}`" @lesson="toLesson" @other="toOther" @toOneClass="toOneClass"></lesson-table>
|
|
|
+ <lesson-table
|
|
|
+ type="usual"
|
|
|
+ :data="i"
|
|
|
+ :batch="`${index + 1}`"
|
|
|
+ :noticeList="noticeList"
|
|
|
+ @lesson="toLesson"
|
|
|
+ @other="toOther"
|
|
|
+ @toOneClass="toOneClass"
|
|
|
+ ></lesson-table>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
<el-row type="flex" v-loading="loading" style="min-height:500px" v-for="(i, index) in unusualList" :key="index">
|
|
|
<el-col :span="8">
|
|
|
- <lesson-table type="unusual" :data="i" :batch="`${index + 1}`" @lesson="toLesson" @other="toOther" @toOneClass="toOneClass"></lesson-table>
|
|
|
+ <lesson-table
|
|
|
+ type="unusual"
|
|
|
+ :data="i"
|
|
|
+ :batch="`${index + 1}`"
|
|
|
+ :noticeList="noticeList"
|
|
|
+ @lesson="toLesson"
|
|
|
+ @other="toOther"
|
|
|
+ @toOneClass="toOneClass"
|
|
|
+ ></lesson-table>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
</detail-frame>
|
|
@@ -62,6 +78,7 @@ const { mapActions: mapDept } = createNamespacedHelpers('dept');
|
|
|
const { mapActions: director } = createNamespacedHelpers('director');
|
|
|
const { mapActions: school } = createNamespacedHelpers('school'); //给选老师组件使用.这个页面请求完就不销毁了
|
|
|
const { mapActions: subject } = createNamespacedHelpers('subject');
|
|
|
+const { mapActions: notice } = createNamespacedHelpers('notice');
|
|
|
export default {
|
|
|
name: 'term-lesson',
|
|
|
props: {},
|
|
@@ -85,6 +102,8 @@ export default {
|
|
|
headTeacherList: [],
|
|
|
schoolList: [],
|
|
|
subjectList: [],
|
|
|
+ //该期通知列表
|
|
|
+ noticeList: [],
|
|
|
};
|
|
|
},
|
|
|
async created() {
|
|
@@ -109,6 +128,8 @@ export default {
|
|
|
);
|
|
|
},
|
|
|
methods: {
|
|
|
+ ...notice({ getNoticeList: 'query' }),
|
|
|
+
|
|
|
...lesson({ getLesson: 'query', plupdate: 'pluralUpdate', autoArrange: 'arrange', confirmLesson: 'confirmLesson' }),
|
|
|
...classes({ getClass: 'query', pcupdate: 'pluralUpdate' }),
|
|
|
|
|
@@ -154,6 +175,7 @@ export default {
|
|
|
let unusualRes = this.dealList(unusualList, lessonList);
|
|
|
this.$set(this, `list`, usualRes);
|
|
|
this.$set(this, `unusualList`, unusualRes);
|
|
|
+ this.toGetNoticeList();
|
|
|
this.loading = false;
|
|
|
},
|
|
|
dealList(classList, lessonList) {
|
|
@@ -680,6 +702,11 @@ export default {
|
|
|
const res = await this.confirmLesson(lessonIds);
|
|
|
this.$checkRes(res, '课表确定成功', res.errmsg || '课表确定失败');
|
|
|
},
|
|
|
+ async toGetNoticeList() {
|
|
|
+ const { planid, termid } = this.defaultOption;
|
|
|
+ const res = await this.getNoticeList({ planid, termid, type: '4' });
|
|
|
+ if (this.$checkRes(res)) this.$set(this, `noticeList`, res.data);
|
|
|
+ },
|
|
|
},
|
|
|
computed: {
|
|
|
...mapState(['user', 'defaultOption']),
|