增加微信支付,商城逻辑,公告

This commit is contained in:
2025-09-05 16:48:53 +08:00
parent e5ace37c68
commit 8530e97ab6
38 changed files with 6430 additions and 1688 deletions

View File

@@ -851,7 +851,8 @@ class MatchingService {
historicalNetBalance: user.historical_net_balance,
totalPendingInflow: user.total_pending_inflow,
availableForAllocation: user.available_for_allocation,
todayOutflow: user.today_outflow
todayOutflow: user.today_outflow,
has_active_allocations:user.has_active_allocations
});
remainingAmount -= maxUserAllocation;
}
@@ -871,7 +872,7 @@ class MatchingService {
// 计算每个用户的剩余可分配容量
for (const allocation of allocations) {
// 获取用户当前的实际余额状态使用has_active_allocations作为实际可分配余额
const maxSafeAmount = Math.abs(allocation.availableForAllocation);
const maxSafeAmount = Math.abs(allocation.has_active_allocations);
const remainingCapacity = maxSafeAmount - allocation.amount;
if (remainingCapacity > 0) {