修改用户合并
This commit is contained in:
parent
eebb013e4e
commit
24e532f980
@ -1729,8 +1729,8 @@ class Auth extends BaseController
|
||||
UserRecharge::where('uid', $user['uid'])->update(['uid' => $targetUser['uid']]);
|
||||
StoreOrderStatus::where('uid', $user['uid'])->update(['uid' => $targetUser['uid']]);
|
||||
if ($user->now_money > 0) {
|
||||
$user->now_money = 0;
|
||||
$targetUser->now_money = bcadd($targetUser->now_money, $user->now_money, 2);
|
||||
$user->now_money = 0;
|
||||
$targetUser->save();
|
||||
}
|
||||
$merchant = Merchant::where('uid', $targetUser['uid'])->find();
|
||||
@ -1767,10 +1767,9 @@ class Auth extends BaseController
|
||||
$merchant->save();
|
||||
}
|
||||
}
|
||||
if (!empty($user)) {
|
||||
$user->wechat_user_id = 0;
|
||||
$user->save();
|
||||
}
|
||||
$user->wechat_user_id = 0;
|
||||
$user->main_uid = $targetUser['uid'];
|
||||
$user->save();
|
||||
Db::commit();
|
||||
} catch (\Throwable $e) {
|
||||
Db::rollback();
|
||||
|
Loading…
x
Reference in New Issue
Block a user