|
@@ -35,7 +35,8 @@
|
|
|
<Poptip trigger="hover" :title="$t('totalAnalysis.echarts_text10')" placement="bottom" @on-popper-show="canEmitSelectChange = true" @on-popper-hide="canEmitSelectChange = false" v-if="originCourseList.length">
|
|
|
<Icon type="ios-funnel" :title="$t('syllabus.search')" @click="doAction('search')" />
|
|
|
<div slot="content">
|
|
|
- <p>{{ $t("courseManage.syllabus.grade") }}</p>
|
|
|
+ <Checkbox v-model="onlyShowConfigCourse" @on-change="onFilterConfig">{{ $t('newCusMgt.configCourse') }}</Checkbox>
|
|
|
+ <p style="margin-top: 10px;">{{ $t("courseManage.syllabus.grade") }}</p>
|
|
|
<Select v-model="filterGrade" clearable @on-change="onFilterGrade" :placeholder="$t('courseManage.syllabus.placeHolder3')" style="margin: 10px 0">
|
|
|
<Option v-for="(item, index) in curPeriod.grades" :value="index" :key="index">{{ item }}</Option>
|
|
|
</Select>
|
|
@@ -207,6 +208,7 @@
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
+ onlyShowConfigCourse:false,
|
|
|
guideModal:false,
|
|
|
sortValue:'grade',
|
|
|
taskGroups:[],
|
|
@@ -595,6 +597,20 @@
|
|
|
this.sortValue = 'grade'
|
|
|
this.canEmitSelectChange = false
|
|
|
},
|
|
|
+ onFilterConfig(val){
|
|
|
+ console.error(val)
|
|
|
+ if(!this.canEmitSelectChange) return
|
|
|
+ let gradeCond = this.filterGrade > -1
|
|
|
+ let subjectCond = this.filterSubjectIndex > -1
|
|
|
+ let nowList = this.originCourseList.filter((i) => (gradeCond ? i.grade === this.filterGrade : true) && (subjectCond ? i.subject.id === this.curPeriod.subjects[this.filterSubjectIndex].id : true));
|
|
|
+ console.error(nowList)
|
|
|
+ this.courseList = !val ? this._.cloneDeep(nowList) : nowList.filter(i => i.count > 0)
|
|
|
+ console.error(this.courseList)
|
|
|
+ if(this.courseList.length){
|
|
|
+ this.onFilterSort(this.sortValue)
|
|
|
+ this.onCourseClick(this.courseList[0], 0);
|
|
|
+ }
|
|
|
+ },
|
|
|
/* 排序方式 */
|
|
|
onFilterSort(val){
|
|
|
console.log(this.canEmitSelectChange)
|
|
@@ -870,6 +886,10 @@
|
|
|
color: #8a8a8a;
|
|
|
|
|
|
.tools {
|
|
|
+
|
|
|
+ .ivu-checkbox-wrapper{
|
|
|
+ white-space: break-spaces;
|
|
|
+ }
|
|
|
.ivu-icon {
|
|
|
font-size: 16px;
|
|
|
margin-left: 10px;
|