修改细节

This commit is contained in:
clay
2022-06-07 22:37:45 +08:00
parent 3a3c657251
commit 25e94c1117
66 changed files with 202 additions and 1438 deletions

View File

@@ -93,8 +93,8 @@
</template>
<script>
import {article, banner, getArticleList, info} from "@/api";
import {getParentNode} from "@/utils/sist";
import {banner, getArticleList} from "@/api";
import {toArticle,lookMoreComment} from "@/utils/sist";
export default {
name: "news_center",
@@ -114,24 +114,11 @@ export default {
//console.log(link)
window.location.href = link;//当前标签页
},
getArticle(news){
toArticle(news,this.width)
},
lookMore(news) {
info(news.id).then(res => {
let info = getParentNode(res.data.encodeId)
console.log(res)
if (info.three == null) {
if (this.width) {
this.$router.push("/pc/" + info.second.encodeId + "?type=" + info.second.type + "&lang=" + sessionStorage.getItem("lang"));
} else {
this.$router.push("/mobile/" + info.second.encodeId + "?type=" + info.second.type + "&lang=" + sessionStorage.getItem("lang"));
}
} else {
if (this.width) {
this.$router.push("/pc/" + info.second.encodeId + "/" + info.three.encodeId + "?type=" + info.second.type + "&lang=" + sessionStorage.getItem("lang"));
} else {
this.$router.push("/mobile/" + info.second.encodeId + "/" + info.three.encodeId + "?type=" + info.second.type + "&lang=" + sessionStorage.getItem("lang"));
}
}
})
lookMoreComment(news,this.width)
},
getList() {
getArticleList({
@@ -142,16 +129,6 @@ export default {
this.newsDate = res.rows
})
},
getArticle(news) {
info(news.id).then(res => {
let info = getParentNode(res.data.encodeId)
if (this.width) {
this.$router.push("/pc/" + info.second.encodeId + "/" + info.three.encodeId + "?id=" + news.id + "&lang=" + sessionStorage.getItem("lang"));
} else {
this.$router.push("/mobile/" + info.second.encodeId + "/" + info.three.encodeId + "?id=" + news.id + "&lang=" + sessionStorage.getItem("lang"));
}
})
},
getBanner() {
banner("NEd5n92EMIpyyBslaNqsRgE").then(res => {
this.bannerDate = res.data

View File

@@ -96,7 +96,7 @@
</div>
</el-col>
<el-col :xs="18" :sm="18" :md="18" :lg="17" :xl="17" :span="17">
<div class="phe_context">
<div class="phe_context" @click="getArticle(item)">
<div class="phe_context_title">{{item.title}}</div>
<div class="phe_context_text" v-html="item.content">
</div>
@@ -115,8 +115,8 @@
<script>
import SlideshowCard from './slideshow_card'
import {getArticleList, info} from "@/api";
import {getParentNode} from "@/utils/sist";
import {getArticleList} from "@/api";
import {toArticle,lookMoreComment} from "@/utils/sist";
export default {
name: "party_building_activities",
@@ -132,24 +132,11 @@ export default {
this.getListData()
},
methods:{
lookMore(news){
info(news.id).then(res=>{
let info = getParentNode(res.data.encodeId)
console.log(res)
if (info.three ==null){
if (this.width){
this.$router.push("/pc/" + info.second.encodeId +"?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}else {
this.$router.push("/mobile/" + info.second.encodeId +"?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}
}else {
if (this.width){
this.$router.push("/pc/" + info.second.encodeId +"/" + info.three.encodeId + "?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}else {
this.$router.push("/mobile/" + info.second.encodeId + "/" + info.three.encodeId + "?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}
}
})
getArticle(item){
toArticle(item,this.width)
},
lookMore(item){
lookMoreComment(item,this.width)
},
getListData(){

View File

@@ -152,7 +152,7 @@
<script>
import {getArticleList, info} from "@/api";
import {parseTime} from '@/utils/ebts'
import {getParentNode} from "@/utils/sist";
import {toArticle,lookMoreComment} from "@/utils/sist";
export default {
name: "scientific_research_trends",
@@ -169,26 +169,12 @@ export default {
},
methods: {
lookMore(news){
info(news.id).then(res=>{
let info = getParentNode(res.data.encodeId)
console.log(res)
if (info.three ==null){
if (this.width){
this.$router.push("/pc/" + info.second.encodeId +"?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}else {
this.$router.push("/mobile/" + info.second.encodeId +"?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}
}else {
if (this.width){
this.$router.push("/pc/" + info.second.encodeId +"/" + info.three.encodeId + "?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}else {
this.$router.push("/mobile/" + info.second.encodeId + "/" + info.three.encodeId + "?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}
}
})
getArticle(news){
toArticle(news,this.width)
},
lookMore(news) {
lookMoreComment(news,this.width)
},
getScientificList() {
getArticleList({
type: "VPteru0OeW6GgYObAewMupY",
@@ -198,26 +184,6 @@ export default {
this.scientificData = res.rows
})
},
getArticle(news){
info(news.id).then(res=>{
let info = getParentNode(res.data.encodeId)
console.log(info)
if (info.three == null){
if (this.width){
this.$router.push("/pc/" + info.second.encodeId +"?id="+news.id + "&type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}else {
this.$router.push("/mobile/" + info.second.encodeId +"?id="+news.id + "&type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}
}else {
if (this.width){
this.$router.push("/pc/" + info.second.encodeId +"/" +info.three.encodeId+"?id="+news.id+"&lang="+sessionStorage.getItem("lang"));
}else {
this.$router.push("/mobile/" + info.second.encodeId +"/" +info.three.encodeId+"?id="+news.id+"&lang="+sessionStorage.getItem("lang"));
}
}
})
},
getAcademiaList() {
getArticleList({
type: "KBwgShsEiDolV91qmaWdWJc",

View File

@@ -76,8 +76,8 @@
</template>
<script>
import {getArticleList, info} from "@/api";
import {getParentNode} from "@/utils/sist";
import {getArticleList} from "@/api";
import {toArticle,lookMoreComment} from "@/utils/sist";
export default {
name: "teaching_student",
@@ -91,25 +91,11 @@ export default {
this.getListData()
},
methods:{
lookMore(news){
info(news.id).then(res=>{
let info = getParentNode(res.data.encodeId)
console.log(res)
if (info.three ==null){
if (this.width){
this.$router.push("/pc/" + info.second.encodeId +"?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}else {
this.$router.push("/mobile/" + info.second.encodeId +"?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}
}else {
if (this.width){
this.$router.push("/pc/" + info.second.encodeId +"/" + info.three.encodeId + "?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}else {
this.$router.push("/mobile/" + info.second.encodeId + "/" + info.three.encodeId + "?type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}
}
})
getArticle(news){
toArticle(news,this.width)
},
lookMore(news) {
lookMoreComment(news,this.width)
},
getListData(){
@@ -124,26 +110,6 @@ export default {
getDay(time){
return new Date(time).getDate()
},
getArticle(news){
info(news.id).then(res=>{
let info = getParentNode(res.data.encodeId)
console.log(info)
if (info.three == null){
if (this.width){
this.$router.push("/pc/" + info.second.encodeId +"?id="+news.id + "&type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}else {
this.$router.push("/mobile/" + info.second.encodeId +"?id="+news.id + "&type=" + info.second.type+"&lang="+sessionStorage.getItem("lang"));
}
}else {
if (this.width){
this.$router.push("/pc/" + info.second.encodeId +"/" +info.three.encodeId+"?id="+news.id+"&lang="+sessionStorage.getItem("lang"));
}else {
this.$router.push("/mobile/" + info.second.encodeId +"/" +info.three.encodeId+"?id="+news.id+"&lang="+sessionStorage.getItem("lang"));
}
}
})
},
getTime(time){
let date = new Date(time);
return date.getFullYear() +"-" + date.getMonth()+1
@@ -192,6 +158,7 @@ export default {
text-overflow:ellipsis; //溢出用省略号显示
white-space:nowrap; //溢出不换行
font-size: 2rem;
cursor:pointer;
font-weight: 600;
padding-right: 2rem;