bug修改。

This commit is contained in:
2026-01-03 10:58:37 +08:00
parent 78c06adaf8
commit 1119e366ee
2 changed files with 4 additions and 2 deletions

View File

@@ -59,7 +59,9 @@ class Invited extends Model
//下级充值推荐人收益计算
public function invited_reward($sub_user_id,$money){
//查询下级用户充值总金额
$sub_user_all_money = db::name('vs_user_recharge')->where('pay_status',2)->sum('money');
$sub_user_all_money = db::name('vs_user_recharge')
->where('user_id', $sub_user_id)
->where('pay_status',2)->sum('money');
if($sub_user_all_money > 1000){
return ['code' => 1, 'msg' => "下级充值金额大于1000元不需返利", 'data' => null];
}