|
|
@@ -70,6 +70,32 @@
|
|
|
@pagination="getSchedules"
|
|
|
@row-dblclick="choose"
|
|
|
>
|
|
|
+ <template #header>
|
|
|
+ <div class="l-flex__auto" />
|
|
|
+ <div class="l-flex__none l-flex--row c-sibling-item">
|
|
|
+ <span>分辨率过滤:</span>
|
|
|
+ <el-switch
|
|
|
+ v-model="isFilterSchedules"
|
|
|
+ class="l-flex__none"
|
|
|
+ active-color="#13ce66"
|
|
|
+ inactive-color="#ff4949"
|
|
|
+ @change="refreshSchedules"
|
|
|
+ />
|
|
|
+ </div>
|
|
|
+ <el-select
|
|
|
+ v-model="scheduleOptions.params.type"
|
|
|
+ class="l-flex__none c-sibling-item o-select"
|
|
|
+ placeholder="请选择类型"
|
|
|
+ @change="refreshSchedules"
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="item in scheduleTypes"
|
|
|
+ :key="item.label"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
<el-table-column
|
|
|
prop="name"
|
|
|
label="排期名称"
|
|
|
@@ -120,7 +146,13 @@ export default {
|
|
|
scheduleOptions: null,
|
|
|
schedule: null,
|
|
|
startDateTime: null,
|
|
|
- endDateTime: null
|
|
|
+ endDateTime: null,
|
|
|
+ scheduleTypes: [
|
|
|
+ { value: void 0, label: '全部类型' },
|
|
|
+ { value: ScheduleType.CALENDAR, label: '日程' },
|
|
|
+ { value: ScheduleType.RECUR, label: '轮播' }
|
|
|
+ ],
|
|
|
+ isFilterSchedules: true
|
|
|
}
|
|
|
},
|
|
|
computed: {
|
|
|
@@ -206,6 +238,12 @@ export default {
|
|
|
schedule.typeName = typeName
|
|
|
return schedule
|
|
|
},
|
|
|
+ refreshSchedules () {
|
|
|
+ const options = this.scheduleOptions
|
|
|
+ options.params.pageNum = 1
|
|
|
+ options.params.resolutionRatio = this.isFilterSchedules ? this.resolutionRatio : void 0
|
|
|
+ this.getSchedules()
|
|
|
+ },
|
|
|
getSchedules () {
|
|
|
const options = this.scheduleOptions
|
|
|
options.error = false
|
|
|
@@ -224,7 +262,11 @@ export default {
|
|
|
if (!this.isReady) {
|
|
|
return
|
|
|
}
|
|
|
- this.scheduleOptions = createListOptions({ status: State.RESOLVED })
|
|
|
+ this.scheduleOptions = createListOptions({
|
|
|
+ status: State.RESOLVED,
|
|
|
+ type: void 0
|
|
|
+ })
|
|
|
+ this.isFilterSchedules = true
|
|
|
this.getSchedules()
|
|
|
this.choosing = true
|
|
|
},
|