|
|
@@ -17,6 +17,7 @@ use app\weixin\model\AccountLog;
|
|
|
use app\weixin\model\UserRechargeLog;
|
|
|
use app\weixin\service\PRedis;
|
|
|
use cmf\controller\AdminBaseController;
|
|
|
+use think\Db;
|
|
|
|
|
|
class PoolsController extends AdminBaseController
|
|
|
{
|
|
|
@@ -727,6 +728,32 @@ class PoolsController extends AdminBaseController
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
+ * 用户资料
|
|
|
+ * @return mixed
|
|
|
+ * @throws \think\db\exception\DataNotFoundException
|
|
|
+ * @throws \think\db\exception\ModelNotFoundException
|
|
|
+ * @throws \think\exception\DbException
|
|
|
+ */
|
|
|
+ public function info(){
|
|
|
+ $id = input('id', 0);
|
|
|
+ $info = Db::name('user')->alias('u')
|
|
|
+ ->leftJoin('user_profile up', 'u.id=up.userid')
|
|
|
+ ->leftJoin('pools p', 'p.user_id=u.id')
|
|
|
+ ->field('up.*,p.expire_at,u.id,u.openid,u.user_login,u.is_top,u.vip_auth,u.top_expire,u.avatar,u.sex,u.birthday,u.user_nickname,u.real_name,u.create_time,u.user_status,u.mobile')
|
|
|
+ ->where(['u.id'=> $id, 'u.user_type'=> 2])
|
|
|
+ ->find();
|
|
|
+ if($info){
|
|
|
+ if(($info['expire_at'] && $info['expire_at'] != '0000-00-00 00:00:00') && $info['expire_at'] <= date('Y-m-d H:i:s')){
|
|
|
+ $info['mobile'] = formatStr($info['mobile']);
|
|
|
+ }
|
|
|
+
|
|
|
+ $info['photolists'] = explode(',', $info['photolist']);
|
|
|
+ }
|
|
|
+ $this->assign($info);
|
|
|
+ return $this->fetch();
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
* 坠海设置
|
|
|
* @return mixed
|
|
|
*/
|