|
|
|
@ -53,7 +53,7 @@ public class WithdrawAuditApplicationService extends BaseApplicationService { |
|
|
|
Long identityId = Objects.nonNull(withdrawAudit.getWalletAccountOrgId()) ? withdrawAudit.getWalletAccountOrgId() : withdrawAudit.getWalletAccountUserId(); |
|
|
|
synchronized (identityId.toString().intern()) { |
|
|
|
WalletAccount walletAccount = walletAccountQueryService.queryByType(identityId, withdrawAudit.getIdentityType()); |
|
|
|
if (Objects.isNull(walletAccount) || walletAccountQueryService.countAvailableWithdrawBalance(walletAccount).compareTo(withdrawAudit.getWithdrawAmount()) >= 0) { |
|
|
|
if (Objects.isNull(walletAccount) || walletAccountQueryService.countAvailableWithdrawBalance(walletAccount).compareTo(withdrawAudit.getWithdrawAmount()) < 0) { |
|
|
|
throw new BizException("超出可提现金额"); |
|
|
|
} |
|
|
|
//todo 改成策略模式 |
|
|
|
|