增加账号展示

This commit is contained in:
zengmingjie 2025-08-20 22:13:54 +08:00
parent 5878fb97b3
commit a3e921b9d6
1 changed files with 4 additions and 1 deletions

View File

@ -54,6 +54,7 @@
<el-dropdown trigger="click">
<img :size="30" src="@/assets/img/menu/iconUser.png" />
<el-dropdown-menu slot="dropdown">
<el-dropdown-item>{{ userName }}</el-dropdown-item>
<el-dropdown-item @click.native="passClick">
修改密码
</el-dropdown-item>
@ -222,7 +223,8 @@ export default {
],
fromItem: {},
dialog: false,
isAdmins: false
isAdmins: false,
userName: ""
};
},
created() {},
@ -238,6 +240,7 @@ export default {
this.isAdmins = JSON.parse(localStorage.getItem("isAdmin"));
this.updateTime();
setInterval(this.updateTime, 1000); //
this.userName = localStorage.getItem("userName");
},
methods: {
updateTime() {