|
@@ -143,13 +143,13 @@ class Usercenter extends Api
|
|
|
$userinfo['is_black'] = $is_black ? 1 : 0;
|
|
|
|
|
|
//关注人数,粉丝人数
|
|
|
- $follow_num = Db::name('user_follow')->where(['uid'=>$this->auth->id])->count('id');
|
|
|
- $fans_num = Db::name('user_follow')->where(['follow_uid'=>$this->auth->id])->count('id');
|
|
|
+ $follow_num = Db::name('user_follow')->where(['uid'=>$uid])->count('id');
|
|
|
+ $fans_num = Db::name('user_follow')->where(['follow_uid'=>$uid])->count('id');
|
|
|
$userinfo['follow_num'] = $follow_num;
|
|
|
$userinfo['fans_num'] = $fans_num;
|
|
|
|
|
|
//访客数
|
|
|
- $visit_num = Db::name('user_visit')->where(['to_uid'=>$this->auth->id])->count('id');
|
|
|
+ $visit_num = Db::name('user_visit')->where(['to_uid'=>$uid])->count('id');
|
|
|
$userinfo['visit_num'] = $visit_num;
|
|
|
|
|
|
//查询是否打过招呼
|