feat: 样式修改,功能修复

This commit is contained in:
2025-09-14 20:28:31 +08:00
parent 3c1650b751
commit f3a1036b64

View File

@@ -69,29 +69,34 @@
<div class="xcontent2-main content-div"> <div class="xcontent2-main content-div">
<!-- 内容导航 --> <!-- 内容导航 -->
<div class="topNav" v-if="!newData"> <div class="topNav" v-if="!newData" style="display: flex; justify-content: center;align-items: center;flex-direction: row;background-color:#fff;">
<div class="search-div nav" style="height: 100px;flex: 1;"> <div>
<div @click="handleTypeClick(ctypeList[0], ctypeList)" class="option-item" <div class="search-div nav" style="height: 100px;flex: 1;">
:class="{ 'option-active': ctypeList[0].checked }"> <div @click="handleTypeClick(ctypeList[0], ctypeList)" class="option-item"
<a>全部</a> :class="{ 'option-active': ctypeList[0].checked }">
<span :class="ctypeList[0].checked ? 'nav-bottbor' : ''"></span> <a>全部</a>
</div> <span :class="ctypeList[0].checked ? 'nav-bottbor' : ''"></span>
</div>
<div @click="handleTypeClick(ctypeList[1], ctypeList)" class="option-item" <div @click="handleTypeClick(ctypeList[1], ctypeList)" class="option-item"
:class="{ 'option-active': ctypeList[1].checked }"> :class="{ 'option-active': ctypeList[1].checked }">
<a>内部专享</a> <a>内部专享</a>
<span :class="ctypeList[1].checked ? 'nav-bottbor' : ''"></span> <span :class="ctypeList[1].checked ? 'nav-bottbor' : ''"></span>
</div>
<div @click="handleTypeClick(ctypeList[2], ctypeList)" class="option-item"
:class="{ 'option-active': ctypeList[2].checked }">
<a>外部精选</a>
<span :class="ctypeList[2].checked ? 'nav-bottbor' : ''"></span>
</div>
</div> </div>
<div @click="handleTypeClick(ctypeList[2], ctypeList)" class="option-item" </div>
:class="{ 'option-active': ctypeList[2].checked }">
<a>外部精选</a> <div style="display: flex;justify-content: space-between; align-items: center;">
<span :class="ctypeList[2].checked ? 'nav-bottbor' : ''"></span> <span style="margin-right: 10px;">请选择年份 </span>
</div>
<div style="display: flex;justify-content: space-between; align-items: center">
<span>请选择年份</span>
<el-select v-model="yearChosen" multiple> <el-select v-model="yearChosen" multiple>
<el-option <el-option
v-for="year in years" v-for="year in years"
v-if="year"
:key="year" :key="year"
:label="year" :label="year"
:value="year"> :value="year">
@@ -99,8 +104,7 @@
</el-select> </el-select>
</div> </div>
</div>
</div> </div>
<!-- 清除 --> <!-- 清除 -->
<!-- <div v-if="stagList.length > 0 && !newData" class="search-div" style="padding: 0;margin-bottom: 20px;"> <!-- <div v-if="stagList.length > 0 && !newData" class="search-div" style="padding: 0;margin-bottom: 20px;">
@@ -273,7 +277,7 @@
</div> </div>
</template> </template>
<script> <script>
import { mapGetters, mapActions } from "vuex"; import {mapActions, mapGetters} from "vuex";
import couresinteract from '@/components/Portal/course/couresinteract.vue'; import couresinteract from '@/components/Portal/course/couresinteract.vue';
import portalHeader from "@/components/PortalHeader.vue"; import portalHeader from "@/components/PortalHeader.vue";
import portalFooter from "@/components/PortalFooter.vue"; import portalFooter from "@/components/PortalFooter.vue";
@@ -288,11 +292,11 @@ import scene from "@/api/modules/scene.js";
import apiUserbasic from "@/api/boe/userbasic.js"; import apiUserbasic from "@/api/boe/userbasic.js";
import interactBar from "@/components/Portal/interactBar.vue"; import interactBar from "@/components/Portal/interactBar.vue";
import courseImage from "@/components/Course/courseImage.vue"; import courseImage from "@/components/Course/courseImage.vue";
import { courseType, getType, toScore, formatDate, formatUserNumber, formatDateByFmt } from "@/utils/tools.js"; import {formatDate, formatUserNumber, toScore} from "@/utils/tools.js";
import { deepClone, param } from "../../../utils";
import apiSearchterm from "@/api/modules/searchterm.js"; import apiSearchterm from "@/api/modules/searchterm.js";
import apiPlace from "@/api/phase2/place.js" import apiPlace from "@/api/phase2/place.js"
import {qualityCourseTimeMark, qualityPageList} from "@/api/phase2" import {qualityCourseTimeMark, qualityPageList} from "@/api/phase2"
export default { export default {
name: "index", name: "index",
components: { components: {
@@ -393,6 +397,8 @@ export default {
}, },
data() { data() {
return { return {
/** 被选择的精品课程*/
courseChosen: void 0,
yearChosen: [], yearChosen: [],
years: [], years: [],
newData: false,//线上品牌系列隐藏 newData: false,//线上品牌系列隐藏
@@ -716,7 +722,8 @@ export default {
handleOptionClick(item, level, list) { handleOptionClick(item, level, list) {
// 线上品牌展示效果 // 线上品牌展示效果
this.newData = item.newData; this.newData = item.newData;
console.log(this.newData); this.courseChosen = item.name
console.log(item.name, "---------");
// 单选,排除法 // 单选,排除法
this.oneList.forEach(one => { this.oneList.forEach(one => {
one.checked = false; one.checked = false;
@@ -1176,14 +1183,18 @@ export default {
// 请求参数预处理 // 请求参数预处理
const params = JSON.parse(JSON.stringify(this.course)) const params = JSON.parse(JSON.stringify(this.course))
// 清除多余的参数 // 清除多余的参数
const {pageIndex, orderField} = params const {pageIndex, orderField, userId} = params
params.pageNum = pageIndex params.pageNum = pageIndex
params.orderByType = orderField params.orderByType = orderField
params.courseSource = this.ctypeList.findIndex(e=>e.checked) params.courseSource = this.ctypeList.findIndex(e => e.checked)
this.yearChosen.length && (params.years = this.yearChosen) this.yearChosen.length && (params.years = this.yearChosen)
params.courseName = this.keyword params.courseName = this.keyword
delete params.userId
params.aid = userId
params.sysType = this.courseChosen
await qualityPageList(params).then(res=>{ console.log(`params`, params)
await qualityPageList(params).then(res => {
this.searching = false; this.searching = false;
console.log(res.status) console.log(res.status)
if (res.status === 200) { if (res.status === 200) {
@@ -2091,7 +2102,7 @@ export default {
::v-deep .el-input { ::v-deep .el-input {
width: 420px; width: 420px;
height: 38px; height: 38px;
margin-bottom: 13px; //margin-bottom: 13px;
.el-input__inner { .el-input__inner {
height: 38px; height: 38px;