|
|
@ -21,11 +21,11 @@ |
|
|
<!-- <secondary-nav /> --> |
|
|
<!-- <secondary-nav /> --> |
|
|
<div class="main-box"> |
|
|
<div class="main-box"> |
|
|
<div class="nav-line"> |
|
|
<div class="nav-line"> |
|
|
<div class="nav-block"> |
|
|
<div class="nav-block" style="border: 1px solid #e5e5e5;"> |
|
|
<el-select v-model="initValue" placeholder="" @change="routerLink"> |
|
|
<el-select v-model="initValue" placeholder="" @change="routerLink"> |
|
|
<el-option |
|
|
<el-option |
|
|
v-for="item in itemList" |
|
|
v-for="(item, index) in itemList" |
|
|
:key="item.value" |
|
|
:key="index" |
|
|
:label="item.label" |
|
|
:label="item.label" |
|
|
:value="item.value"> |
|
|
:value="item.value"> |
|
|
</el-option> |
|
|
</el-option> |
|
|
@ -70,29 +70,29 @@ export default { |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
computed: { |
|
|
computed: { |
|
|
title() { |
|
|
// title() { |
|
|
let key = this.cid; |
|
|
// let key = this.cid; |
|
|
switch (key) { |
|
|
// switch (key) { |
|
|
case 'novice': |
|
|
// case 'novice': |
|
|
return this.$t('college.noviceTutorial') |
|
|
// return this.$t('college.noviceTutorial') |
|
|
case 'strategy': |
|
|
// case 'strategy': |
|
|
return this.$t('college.TradingStrategy') |
|
|
// return this.$t('college.TradingStrategy') |
|
|
case 'research': |
|
|
// case 'research': |
|
|
return this.$t('college.industryResearch') |
|
|
// return this.$t('college.industryResearch') |
|
|
case 'dictionary': |
|
|
// case 'dictionary': |
|
|
return this.$t('college.dictionary') |
|
|
// return this.$t('college.dictionary') |
|
|
case 'report': |
|
|
// case 'report': |
|
|
return this.$t('college.media') |
|
|
// return this.$t('college.media') |
|
|
case 'OkChain': |
|
|
// case 'OkChain': |
|
|
return 'OkChain' |
|
|
// return 'OkChain' |
|
|
} |
|
|
// } |
|
|
} |
|
|
// } |
|
|
}, |
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
getArticleList() { |
|
|
getArticleList() { |
|
|
College.getArticleList(this.cid).then(data => { |
|
|
College.getArticleList(this.cid).then(data => { |
|
|
this.articleList = data; |
|
|
this.articleList = data; |
|
|
console.log(this.articleList, '文章列表') |
|
|
console.log(this.articleList, '文章列表'); |
|
|
}).catch(); |
|
|
}).catch(); |
|
|
}, |
|
|
}, |
|
|
getCollegeLinks() { |
|
|
getCollegeLinks() { |
|
|
@ -124,12 +124,13 @@ export default { |
|
|
watch: { |
|
|
watch: { |
|
|
$route() { |
|
|
$route() { |
|
|
this.cid = this.$route.params.cid; |
|
|
this.cid = this.$route.params.cid; |
|
|
|
|
|
this.getCollegeLinks();// 为了获取初始样式,多请求一下 |
|
|
this.getArticleList(); |
|
|
this.getArticleList(); |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
created() { |
|
|
created() { |
|
|
this.getArticleList(); |
|
|
|
|
|
this.getCollegeLinks(); |
|
|
this.getCollegeLinks(); |
|
|
|
|
|
this.getArticleList(); |
|
|
// if (this.$route.query.cname != '' && this.$route.query.cname != null && this.$route.query.cname != undefined ) { |
|
|
// if (this.$route.query.cname != '' && this.$route.query.cname != null && this.$route.query.cname != undefined ) { |
|
|
// this.initValue = this.$route.query.cname; |
|
|
// this.initValue = this.$route.query.cname; |
|
|
// } |
|
|
// } |
|
|
|