feat(IndexController): 增加真实姓名获取功能
This commit is contained in:
parent
3be7efb356
commit
f45f6f63be
@ -137,7 +137,11 @@ class IndexController extends BaseLikeController
|
||||
// }
|
||||
$res = Db::connect('demo')->name('user_recharge')->where($where)->limit(20)->select()->each(function ($item) {
|
||||
if ($item['uid']) {
|
||||
$item['nickname'] = Db::connect('demo')->name('user')->where('id', $item['uid'])->value('nickname');
|
||||
$find = Db::connect('demo')->name('user')->where('id', $item['uid'])->field('real_name,nickname')->find();
|
||||
$item['nickname']=$find['real_name']??'';
|
||||
if($item['nickname']==''){
|
||||
$item['nickname'] = $find['nickname']??'';
|
||||
}
|
||||
} else {
|
||||
$item['nickname'] = '';
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user