luobisheng
2022-11-22 35c30ecf074b292e955d96df7a713a2166daff0e
src/views/layout/components/Header/index.vue
@@ -182,13 +182,13 @@
    // 设置用户基本信息
    async setLoginInfo() {
      const info = JSON.parse(sessionStorage.getItem('user'));
      this.getMessage();
      if (info) {
        this.user = info;
      } else {
        this.user = await this.getLoginInfo();
      }
      this.show = true
      this.show = true;
      this.getMessage();
    },
    // 获取登录用户信息
    async getLoginInfo(){
@@ -201,8 +201,7 @@
        return res.data;
    },
    getMessage() {
      const userInfo = JSON.parse(sessionStorage.getItem('user'));
      users.getMessageAuditList({ userId: userInfo.user.id })
      users.getMessageAuditList({ userId: this.user.user.id })
          .then(res => {
            this.menuMessageList = res;
            this.menuMessageList.forEach(item => {