mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-11 03:46:44 +08:00
选中样式
This commit is contained in:
@@ -513,6 +513,7 @@ export default {
|
|||||||
totalPages: 1,
|
totalPages: 1,
|
||||||
localSessionKey: this.$xpage.constants.localCourseFiltersKey,
|
localSessionKey: this.$xpage.constants.localCourseFiltersKey,
|
||||||
hotTagsList: [],
|
hotTagsList: [],
|
||||||
|
isAllHotTagsSelected: true,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
// 受众需要每次刷新
|
// 受众需要每次刷新
|
||||||
@@ -592,6 +593,7 @@ export default {
|
|||||||
this.hotTagsList.forEach(tag => {
|
this.hotTagsList.forEach(tag => {
|
||||||
tag.checked = false;
|
tag.checked = false;
|
||||||
});
|
});
|
||||||
|
this.isAllHotTagsSelected = true;
|
||||||
// 清空course.tags
|
// 清空course.tags
|
||||||
this.course.tags = '';
|
this.course.tags = '';
|
||||||
|
|
||||||
@@ -600,8 +602,8 @@ export default {
|
|||||||
},
|
},
|
||||||
handleTagClick(item, list,type) {
|
handleTagClick(item, list,type) {
|
||||||
console.info('切换标签 item = ' + item)
|
console.info('切换标签 item = ' + item)
|
||||||
|
this.isAllHotTagsSelected = false;
|
||||||
item.checked = !item.checked;
|
item.checked = !item.checked;
|
||||||
|
|
||||||
// 更新course.tags
|
// 更新course.tags
|
||||||
const checkedTags = this.hotTagsList.filter(tag => tag.checked);
|
const checkedTags = this.hotTagsList.filter(tag => tag.checked);
|
||||||
let tagIds = checkedTags.map(tag => tag.id).join(',');
|
let tagIds = checkedTags.map(tag => tag.id).join(',');
|
||||||
|
|||||||
Reference in New Issue
Block a user