Commit b2b867a5 authored by 吴冠's avatar 吴冠

footer

parent 7a1cfc22
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<div class="t4">{{item.title}}</div> <div class="t4">{{item.title}}</div>
<ul> <ul>
<li class="t1" v-for="(item,index) in item.list" :key="index"> <li class="t1" v-for="(item,index) in item.list" :key="index">
<a :href="item.url" class="textcolor">{{item.name}}</a> <span class="textcolor" @click="xxxxmove(item.url)">{{item.name}}</span>
</li> </li>
</ul> </ul>
</div> </div>
...@@ -26,6 +26,11 @@ import {getMessagephone} from '@/common/list.js' ...@@ -26,6 +26,11 @@ import {getMessagephone} from '@/common/list.js'
this.footList[3].list[1].name=`电子邮箱 : ${res.data.email}` this.footList[3].list[1].name=`电子邮箱 : ${res.data.email}`
}); });
}, },
methods:{
xxxxmove(url){
this.$router.push(url);
}
},
data() { data() {
return { return {
/* email:'605664467@qq.com', */ /* email:'605664467@qq.com', */
...@@ -46,11 +51,11 @@ import {getMessagephone} from '@/common/list.js' ...@@ -46,11 +51,11 @@ import {getMessagephone} from '@/common/list.js'
}, },
{ {
title: "关于我们", title: "关于我们",
list: [{name:"诚招英才"}, {name:"联系我们"}] list: [{name:"诚招英才",url:'/message/news?id=126'}, {name:"联系我们",url:'/message/news?id=126'}]
}, },
{ {
title: "客服中心", title: "客服中心",
list: [{name:"帮助中心"}, {name:"在线客服"}] list: [{name:"帮助中心",url:'/message/news?id=127'}, {name:"在线客服",url:'/message/news?id=127'}]
}, },
/* */ /* */
{ {
...@@ -59,9 +64,6 @@ import {getMessagephone} from '@/common/list.js' ...@@ -59,9 +64,6 @@ import {getMessagephone} from '@/common/list.js'
}, },
] ]
} }
},
mothods:{
} }
} }
</script> </script>
......
...@@ -46,13 +46,30 @@ import inDex from '@/pages/index.vue' ...@@ -46,13 +46,30 @@ import inDex from '@/pages/index.vue'
} }
}, },
mounted(){ mounted(){
/* if(window.location.href="") */
let href = window.location.href.split("?id=")[1]
if(href=="127"){
this.nav = 5
}
if(href=="126"){
this.nav = 5
}
let path = this.$route.path; let path = this.$route.path;
/* */
console.log("path======",path) console.log("path======",path)
console.log(path!="/") console.log(path!="/")
if(path!="/"){ if(path!="/"){
path="/" if(path.startsWith("/message/news")){
this.$router.push(path) this.$router.push("/message/news?id=127")
this.$router.push("/message/news")
}else{
path="/";
this.$router.push(path);
}
/* path="/" */
/* this.$router.push(path) */
} }
/* if(path=="/"){ /* if(path=="/"){
this.nav = "0"; this.nav = "0";
...@@ -61,6 +78,7 @@ import inDex from '@/pages/index.vue' ...@@ -61,6 +78,7 @@ import inDex from '@/pages/index.vue'
}else if(path.indexOf("/notice")==0){ }else if(path.indexOf("/notice")==0){
this.nav = "4"; this.nav = "4";
} */ } */
switch (path) { switch (path) {
case '/': case '/':
this.nav = "0"; this.nav = "0";
...@@ -92,6 +110,15 @@ import inDex from '@/pages/index.vue' ...@@ -92,6 +110,15 @@ import inDex from '@/pages/index.vue'
case "/notice/abortive/": case "/notice/abortive/":
this.nav = "4"; this.nav = "4";
break; break;
case "/notice/abortive/":
this.nav = "4";
break;
case "/message/news?id=126":
this.nav = "5";
break;
case "/message/news?id=127":
this.nav = "5";
break;
} }
}, },
methods: { methods: {
...@@ -102,13 +129,6 @@ import inDex from '@/pages/index.vue' ...@@ -102,13 +129,6 @@ import inDex from '@/pages/index.vue'
getindex() { getindex() {
let path = this.$route.path; let path = this.$route.path;
/* if(path=="/"){
this.nav = "0";
}else if(path.indexOf("/message")==0){
this.nav = "5";
}else if(path.indexOf("/notice")==0){
this.nav = "4";
} */
switch (path) { switch (path) {
case '/': case '/':
this.nav = "0"; this.nav = "0";
...@@ -140,6 +160,12 @@ import inDex from '@/pages/index.vue' ...@@ -140,6 +160,12 @@ import inDex from '@/pages/index.vue'
case "/notice/abortive/": case "/notice/abortive/":
this.nav = "4"; this.nav = "4";
break; break;
case "/message/news?id=126":
this.nav = "5";
break;
case "/message/news?id=127":
this.nav = "5";
break;
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment