Browse Source

后院首页用户

wzq 5 years ago
parent
commit
ddcf3d018a
1 changed files with 4 additions and 0 deletions
  1. 4 0
      app/Repositories/BeanRepository.php

+ 4 - 0
app/Repositories/BeanRepository.php

@@ -167,6 +167,8 @@ class BeanRepository
         $uid = $token['user']->uid;
         $bean = Redis::ZSCORE('user_rainbow_bean'.$today,$uid);
 
+        $userInfo = $this->userInfo($uid);
+
         $star_home = [];
         $user_bean = Redis::get('my_bean');
         Log::debug($user_bean);
@@ -205,6 +207,8 @@ class BeanRepository
             $star_home['backyard']['backyard_open'] = 0;
             $star_home['backyard']['backyard_img'] = '';
         }
+        $star_home['user']['username'] = $userInfo['username'];
+        $star_home['user']['avatar'] = $userInfo['avatar'];
         return $star_home;
 
     }