[fix][V]:完成对接用户名接口

master
Romesum 5 years ago
parent 147bb0f028
commit 3d3c7f3e6b

@ -1,6 +1,6 @@
<template> <template>
<div> <div>
<home :names="homePrarms" user="林大池" ></home> <home :names="homeParams" :user="nickname"></home>
</div> </div>
</template> </template>
@ -15,15 +15,24 @@
}, },
data() { data() {
return { return {
homePrarms:[ nickname: '未登录',
{ name:'个人中心',func:()=> { homeParams: [
{
name: '个人中心', func: () => {
console.log(this.$router) console.log(this.$router)
this.$router.push('/teacher/personal') this.$router.push('/teacher/personal')
}}, }
{name:'申请实验室' ,func:()=> { },
this.$router.push('/teacher/applyLab')}}, {
{name:'我的课表',func:()=> { name: '申请实验室', func: () => {
this.$router.push('/teacher/myCourse')}} this.$router.push('/teacher/applyLab')
}
},
{
name: '我的课表', func: () => {
this.$router.push('/teacher/myCourse')
}
}
] ]
} }
}, },
@ -36,8 +45,9 @@
}, 1000) }, 1000)
} }
}, },
mounted() { async mounted() {
console.log(this.homePrarms) this.nickname = await get('lb/user/getUserName')
console.log(this.homeParams)
} }
} }
</script> </script>

Loading…
Cancel
Save