diff --git a/app/data/service/UserRebateService.php b/app/data/service/UserRebateService.php index b4f5c6f72..a83f20863 100644 --- a/app/data/service/UserRebateService.php +++ b/app/data/service/UserRebateService.php @@ -23,7 +23,9 @@ class UserRebateService extends Service $count = $this->app->db->name('DataUserTransfer')->whereRaw("uid='{$uuid}' and status>0")->sum('amount'); $total = $this->app->db->name('DataUserRebate')->whereRaw("uid='{$uuid}' and status=1 and deleted=0")->sum('amount'); $locks = $this->app->db->name('DataUserRebate')->whereRaw("uid='{$uuid}' and status=0 and deleted=0")->sum('amount'); - $this->app->db->name('DataUser')->where(['id' => $uuid])->update(['rebate_total' => $total, 'rebate_used' => $count, 'rebate_lock' => $locks]); + $this->app->db->name('DataUser')->where(['id' => $uuid])->update([ + 'rebate_total' => $total, 'rebate_used' => $count, 'rebate_lock' => $locks, + ]); } else { $count = $this->app->db->name('DataUserTransfer')->whereRaw("status>0")->sum('amount'); $total = $this->app->db->name('DataUserRebate')->whereRaw("status=1 and deleted=0")->sum('amount');