修复提现金额问题

This commit is contained in:
2024-09-30 10:59:26 +08:00
parent df87e9c00b
commit 23f8e27ee6

View File

@@ -327,6 +327,9 @@ class EplpayCallbackController extends \yii\web\Controller
'user_id' => 0,
'user_type' => 2
])->one();
if (!$platformAccount) {
throw new Exception('平台账户不存在');
}
$platformAccount->able_cash = bcsub($platformAccount->able_cash, $chargeCpr->charge_cash, 2);
$platformAccount->charge_cash = bcadd($platformAccount->charge_cash, $chargeCpr->charge_cash, 2);
$platformAccount->saveOrFail();