buyer一些样式和一个弹框

This commit is contained in:
夜良king
2021-12-28 17:51:23 +08:00
parent 0a0066fe5c
commit 76d028277a
3 changed files with 31 additions and 4 deletions

View File

@@ -65,8 +65,21 @@ export default {
};
},
computed: {
userInfo () { // 用户信息
return JSON.parse(Storage.getItem('userInfo'));
userInfo () { // 用户信息
if(Storage.getItem('userInfo')){
return JSON.parse(Storage.getItem('userInfo'));
} else{
this.$Modal.confirm({
title:'登录失效',
content:"<p>登录已失效,请再次登录</p>",
onOk:()=>{
if(true){
this.$router.push('/login');
}
}
})
return {}
}
}
},