This commit is contained in:
670788339
2025-11-09 15:25:13 +08:00
parent 73026b0ab5
commit 89a9be76d4

View File

@@ -148,6 +148,18 @@
<span v-if="cinfo.type == 40" class="course-type-left">学习项目</span> <span v-if="cinfo.type == 40" class="course-type-left">学习项目</span>
</div> </div>
<div class="course-title two-line-ellipsis" :title="cinfo.title" v-html="cinfo.courseName"></div> <div class="course-title two-line-ellipsis" :title="cinfo.title" v-html="cinfo.courseName"></div>
<!-- 添加标签显示区域 -->
<div class="course-tags" v-if="cinfo.tagsList && cinfo.tagsList.length > 0">
<el-tag
v-for="(tag, tagIndex) in cinfo.tagsList"
:key="tagIndex"
size="mini"
type="info" style="margin: 2px 2px; border-radius: 2px;"
:style="{ color: isTagMatched(tag) ? '#387DF7' : '#333333' }"
>
{{ tag }}
</el-tag>
</div>
<!-- 关键字 --> <!-- 关键字 -->
<div class="keywordInfo-every"> <div class="keywordInfo-every">
<div class="keywordInfo" v-for="(keyword, index) in cinfo.keywordsActive" :key="index"> <div class="keywordInfo" v-for="(keyword, index) in cinfo.keywordsActive" :key="index">
@@ -653,7 +665,12 @@ export default {
this.navTitle = [] this.navTitle = []
this.searchData(); this.searchData();
}, },
isTagMatched(tag) {
// 检查stagList中是否有匹配的标签
return this.stagList.some(searchTag =>
searchTag.tagName === tag || searchTag.name === tag
);
},
// 导航全选 // 导航全选
handleTypeAllClick(t) { handleTypeAllClick(t) {
if (t == 1) { if (t == 1) {
@@ -1887,7 +1904,7 @@ export default {
right: 23.5%; right: 23.5%;
// bottom: 26%; // bottom: 26%;
top: 0; top: 0;
height: 20; height: 20px;
line-height: 20px; line-height: 20px;
font-size: 12px; font-size: 12px;
color: #FFFFFF; color: #FFFFFF;