@ -1669,6 +1669,13 @@ class OrdersController extends CommonController
//更新用户余额,创建流水记录
$customer_balance = $refund->customer->balance - $refund->money;
if ($customer_balance < 0) {
return response()->json([
"errorcode" => "0",
"errormsg" => "客户余额为负异常,存在重复退款操作。"
]);
}
$refund->customer->update([
"balance" => $customer_balance