|
|
@@ -123,6 +123,8 @@ class AwardLake extends BaseModel
|
|
|
if (count($users) <= 0){
|
|
|
return true;
|
|
|
}
|
|
|
+ @file_put_contents('quanju.txt',json_encode($users)."-参加分红的人员\r\n",8);
|
|
|
+
|
|
|
$every = bcdiv($lake['num'], count($users), 2); //每个用户分得的奖励金额
|
|
|
if ($every <= 0) {
|
|
|
self::where('id', $lake['id'])->update(['send_time' => time()]);
|
|
|
@@ -156,6 +158,7 @@ class AwardLake extends BaseModel
|
|
|
//todo end
|
|
|
$real_send = bcadd($real_send, $every, 2);
|
|
|
$UserRepository = app()->make(UserRepository::class);
|
|
|
+
|
|
|
$UserRepository->checkAward($user['uid']);
|
|
|
}
|
|
|
AwardLakeLog::expend($lake['id'], 'send', $real_send, 0, '奖池分红');
|