Merge branch 'zhengjie' of pplokijuhyg/falvpingtai into master

This commit is contained in:
asd 2019-12-03 09:42:16 +08:00
commit be71aae0c7
3 changed files with 24 additions and 4 deletions

View File

@ -5,7 +5,7 @@
<div class="mnuelist"> <div class="mnuelist">
<div>首页</div> <div>首页</div>
<div>我的主页</div> <div>我的主页</div>
<div>退出登录</div> <div>{{menu3}}</div>
</div> </div>
</van-popup> </van-popup>
<div class="head"> <div class="head">
@ -98,11 +98,17 @@ export default {
data() { data() {
return { return {
show: false, show: false,
serch:"" serch:"",
menu3:""
}; };
}, },
mounted(){ mounted(){
this.serch=this.$route.query.word this.serch=this.$route.query.word
if (localStorage.getItem("token") == ""){
this.menu3="登录"
}else{
this.menu3="退出登录"
}
}, },
methods: { methods: {
isshow() { isshow() {

View File

@ -11,7 +11,7 @@
我的主页</div> 我的主页</div>
<div @click="tab(2)"> <div @click="tab(2)">
<img src="../assets/logout.png" alt="" class="icon"> <img src="../assets/logout.png" alt="" class="icon">
退出登录</div> {{token==''?'登录':'退出登录'}}</div>
</div> </div>
</van-popup> </van-popup>
<div class="head"> <div class="head">
@ -107,9 +107,19 @@ export default {
data() { data() {
return { return {
show: false, show: false,
serch: "" serch: "",
token:""
}; };
}, },
mounted(){
window.console.log(localStorage.getItem("token")=='',465)
this.token=localStorage.getItem("token")
// if (localStorage.getItem("token") == ""){
// this.menu3=""
// }else{
// this.menu3="退"
// }
},
methods: { methods: {
isshow() { isshow() {
this.show = !this.show; this.show = !this.show;

View File

@ -74,6 +74,9 @@ export default {
miao: 60 miao: 60
}; };
}, },
mounted(){
window.localStorage.setItem('token','')
},
methods: { methods: {
open() { open() {
this.ifshow = true; this.ifshow = true;
@ -124,6 +127,7 @@ export default {
} }
}, },
sub() { sub() {
let t = this; let t = this;
window.console.log(t.ifsign, 4859); window.console.log(t.ifsign, 4859);
if (t.ifsign) { if (t.ifsign) {