|
@@ -727,7 +727,7 @@ class Auth
|
|
//vip
|
|
//vip
|
|
$userwallet = Db::name('user_wallet')->where('user_id',$this->id)->find();
|
|
$userwallet = Db::name('user_wallet')->where('user_id',$this->id)->find();
|
|
$userinfo['vip_endtime'] = $userwallet['vip_endtime'];
|
|
$userinfo['vip_endtime'] = $userwallet['vip_endtime'];
|
|
- $userinfo['is_vip'] = $this->is_vip($userwallet['vip_endtime'],$userwallet['vip_level']);
|
|
|
|
|
|
+ $userinfo['vip_level'] = $userwallet['vip_level'];
|
|
$userinfo['vip_chat_discount'] = config('site.vip_chat_discount') ? : 10; //vip聊天折扣
|
|
$userinfo['vip_chat_discount'] = config('site.vip_chat_discount') ? : 10; //vip聊天折扣
|
|
$userinfo['vip_video_discount'] = config('site.vip_video_discount') ? : 10; //vip视频折扣
|
|
$userinfo['vip_video_discount'] = config('site.vip_video_discount') ? : 10; //vip视频折扣
|
|
|
|
|
|
@@ -771,14 +771,14 @@ class Auth
|
|
}
|
|
}
|
|
|
|
|
|
//查询财富等级和魅力等级
|
|
//查询财富等级和魅力等级
|
|
- $wallet_info = Db::name('user_wallet')->where(['user_id' => $this->id])->find();
|
|
|
|
- $wealth_level = Db::name('wealth_level')->where(['value' => ['elt', $wallet_info['pay_money']]])->order('id desc')->find();
|
|
|
|
|
|
+
|
|
|
|
+ $wealth_level = Db::name('wealth_level')->where(['value' => ['elt', $userwallet['pay_money']]])->order('id desc')->find();
|
|
if ($wealth_level) {
|
|
if ($wealth_level) {
|
|
$userinfo['wealth_level'] = localpath_to_netpath($wealth_level['image']);
|
|
$userinfo['wealth_level'] = localpath_to_netpath($wealth_level['image']);
|
|
} else {
|
|
} else {
|
|
$userinfo['wealth_level'] = '';
|
|
$userinfo['wealth_level'] = '';
|
|
}
|
|
}
|
|
- $charm_level = Db::name('charm_level')->where(['value' => ['elt', $wallet_info['get_money']]])->order('id desc')->find();
|
|
|
|
|
|
+ $charm_level = Db::name('charm_level')->where(['value' => ['elt', $userwallet['get_money']]])->order('id desc')->find();
|
|
if ($charm_level) {
|
|
if ($charm_level) {
|
|
$userinfo['charm_level'] = localpath_to_netpath($charm_level['image']);
|
|
$userinfo['charm_level'] = localpath_to_netpath($charm_level['image']);
|
|
} else {
|
|
} else {
|
|
@@ -801,10 +801,10 @@ class Auth
|
|
$userinfo['dongtai_num'] = Db::name('topic_dongtai')->where(['user_id' => $this->id, 'is_hidden' => 0, 'type' => ['in', [1, 2]], 'status' => 0, 'auit_status' => 1])->count();
|
|
$userinfo['dongtai_num'] = Db::name('topic_dongtai')->where(['user_id' => $this->id, 'is_hidden' => 0, 'type' => ['in', [1, 2]], 'status' => 0, 'auit_status' => 1])->count();
|
|
|
|
|
|
//收益
|
|
//收益
|
|
- $userinfo['money'] = model('wallet')->getWallet($this->id,'money');
|
|
|
|
|
|
+ $userinfo['money'] = $userwallet['money'];
|
|
|
|
|
|
//金币
|
|
//金币
|
|
- $userinfo['gold'] = model('wallet')->getWallet($this->id,'gold');
|
|
|
|
|
|
+ $userinfo['gold'] = $userwallet['gold'];
|
|
|
|
|
|
return $userinfo;
|
|
return $userinfo;
|
|
}
|
|
}
|