|
|
@@ -440,14 +440,10 @@ public class WalletAgentService extends ServiceImpl<WalletAgentMapper, WalletAge
|
|
|
return BaseResult.failed("金额不能大于待收代理费");
|
|
|
}
|
|
|
|
|
|
- Long userId = LoginUserHolder.getUserId();
|
|
|
- LocalDateTime now = LocalDateTime.now();
|
|
|
String orderNo = "M" + System.currentTimeMillis();
|
|
|
|
|
|
BigDecimal newPre = walletAgent.getPreBalance().subtract(manualDto.getAmount());
|
|
|
walletAgent.setPreBalance(newPre);
|
|
|
- walletAgent.setUpdateBy(userId);
|
|
|
- walletAgent.setUpdateTime(now);
|
|
|
baseMapper.updateById(walletAgent);
|
|
|
|
|
|
WalletAgentBalance balance = new WalletAgentBalance();
|
|
|
@@ -461,10 +457,6 @@ public class WalletAgentService extends ServiceImpl<WalletAgentMapper, WalletAge
|
|
|
balance.setTradingAmount(walletAgent.getTradingAmount());
|
|
|
balance.setStatus(ExecutionStatusEnum.SUCCESS.getCode());
|
|
|
balance.setRemark(manualDto.getRemark());
|
|
|
- balance.setCreateBy(userId);
|
|
|
- balance.setCreateTime(now);
|
|
|
- balance.setUpdateBy(userId);
|
|
|
- balance.setUpdateTime(now);
|
|
|
balance.setDelFlag(0);
|
|
|
walletAgentBalanceMapper.insert(balance);
|
|
|
|
|
|
@@ -476,10 +468,6 @@ public class WalletAgentService extends ServiceImpl<WalletAgentMapper, WalletAge
|
|
|
record.setStatus(PayStatusEnum.PAID.getCode());
|
|
|
record.setData("");
|
|
|
record.setRemark(manualDto.getRemark());
|
|
|
- record.setCreateBy(userId);
|
|
|
- record.setCreateTime(now);
|
|
|
- record.setUpdateBy(userId);
|
|
|
- record.setUpdateTime(now);
|
|
|
record.setDelFlag(0);
|
|
|
walletAgentRecordMapper.insert(record);
|
|
|
return BaseResult.success();
|
|
|
@@ -522,9 +510,6 @@ public class WalletAgentService extends ServiceImpl<WalletAgentMapper, WalletAge
|
|
|
throw new RuntimeException(e);
|
|
|
}
|
|
|
|
|
|
- Long userId = LoginUserHolder.getUserId();
|
|
|
- LocalDateTime now = LocalDateTime.now();
|
|
|
-
|
|
|
WalletAgentRecord record = new WalletAgentRecord();
|
|
|
record.setAgentId(walletAgent.getId());
|
|
|
record.setOrderNo(orderNo);
|
|
|
@@ -533,10 +518,6 @@ public class WalletAgentService extends ServiceImpl<WalletAgentMapper, WalletAge
|
|
|
record.setStatus(PayStatusEnum.PAYABLE.getCode());
|
|
|
record.setData(JSONObject.toJSONString(pay.getData()));
|
|
|
record.setRemark(payDto.getRemark());
|
|
|
- record.setCreateBy(userId);
|
|
|
- record.setCreateTime(now);
|
|
|
- record.setUpdateBy(userId);
|
|
|
- record.setUpdateTime(now);
|
|
|
record.setDelFlag(0);
|
|
|
walletAgentRecordMapper.insert(record);
|
|
|
|
|
|
@@ -544,8 +525,6 @@ public class WalletAgentService extends ServiceImpl<WalletAgentMapper, WalletAge
|
|
|
BigDecimal newTrading = (walletAgent.getTradingAmount() == null ? BigDecimal.ZERO : walletAgent.getTradingAmount()).add(payDto.getPayAmount());
|
|
|
walletAgent.setPreBalance(newPre);
|
|
|
walletAgent.setTradingAmount(newTrading);
|
|
|
- walletAgent.setUpdateBy(userId);
|
|
|
- walletAgent.setUpdateTime(now);
|
|
|
baseMapper.updateById(walletAgent);
|
|
|
|
|
|
WalletAgentBalance balance = new WalletAgentBalance();
|
|
|
@@ -559,10 +538,6 @@ public class WalletAgentService extends ServiceImpl<WalletAgentMapper, WalletAge
|
|
|
balance.setTradingAmount(newTrading);
|
|
|
balance.setStatus(ExecutionStatusEnum.IN_PROGRESS.getCode());
|
|
|
balance.setRemark(payDto.getRemark());
|
|
|
- balance.setCreateBy(userId);
|
|
|
- balance.setCreateTime(now);
|
|
|
- balance.setUpdateBy(userId);
|
|
|
- balance.setUpdateTime(now);
|
|
|
balance.setDelFlag(0);
|
|
|
walletAgentBalanceMapper.insert(balance);
|
|
|
|