提交 391d2fb0 作者: 张小凤

Requirements(update)

上级 67cc6ba6
...@@ -1051,6 +1051,16 @@ public class RequirementsServiceImpl implements RequirementsService { ...@@ -1051,6 +1051,16 @@ public class RequirementsServiceImpl implements RequirementsService {
BigDecimal freeze = orderAmount.multiply(new BigDecimal(0.3)).setScale(2, BigDecimal.ROUND_HALF_UP); BigDecimal freeze = orderAmount.multiply(new BigDecimal(0.3)).setScale(2, BigDecimal.ROUND_HALF_UP);
//微信支付金额大于需要退款金额 //微信支付金额大于需要退款金额
if (weChat.compareTo(residueOrderAmount) == 1) { if (weChat.compareTo(residueOrderAmount) == 1) {
//云享金扣除多少
// publisherWalletFlowVO.setCashAmount(requirementsInfoDO.getCashAmount().negate());
//佣金扣除多少
// publisherWalletFlowVO.setSalaryAmount(requirementsInfoDO.getSalaryAmount().negate());
//违约云享金多少
publisherWalletFlowVO.setYxjCashPledge(requirementsInfoDO.getCashAmount().negate());
//违约佣金
publisherWalletFlowVO.setSalaryCashPledge(requirementsInfoDO.getSalaryAmount().negate());
//用户退百分之七十的费用 //用户退百分之七十的费用
refundWeChat = residueOrderAmount; refundWeChat = residueOrderAmount;
BigDecimal multiply = refundWeChat.multiply(new BigDecimal(100)); BigDecimal multiply = refundWeChat.multiply(new BigDecimal(100));
...@@ -1076,16 +1086,29 @@ public class RequirementsServiceImpl implements RequirementsService { ...@@ -1076,16 +1086,29 @@ public class RequirementsServiceImpl implements RequirementsService {
publisherWalletFlowVO.setYxjCashPledge(requirementsInfoDO.getCashAmount().subtract(residueAmount).negate()); publisherWalletFlowVO.setYxjCashPledge(requirementsInfoDO.getCashAmount().subtract(residueAmount).negate());
} }
if (returnToWechat.compareTo(requirementsInfoDO.getSalaryAmount()) == 0) {
publisherWalletFlowVO.setSalaryAmount(returnToWechat);
}
//如果退回的佣金小于支付的佣金 //如果退回的佣金小于支付的佣金
if (returnToWechat.compareTo(requirementsInfoDO.getSalaryAmount()) == -1) { if (returnToWechat.compareTo(requirementsInfoDO.getSalaryAmount()) == -1) {
residueAmount = requirementsInfoDO.getSalaryAmount().subtract(returnToWechat); residueAmount = requirementsInfoDO.getSalaryAmount().subtract(returnToWechat);
//one //one
publisherWalletFlowVO.setSalaryAmount(requirementsInfoDO.getSalaryAmount().subtract(residueAmount)); publisherWalletFlowVO.setSalaryAmount(requirementsInfoDO.getSalaryAmount().subtract(residueAmount));
publisherWalletFlowVO.setSalaryCashPledge(residueAmount.negate()); publisherWalletFlowVO.setSalaryCashPledge(residueAmount.negate());
//修改2
//修改三
if (residueAmount.compareTo(BigDecimal.ZERO) == 1) {
publisherWalletFlowVO.setYxjCashPledge(requirementsInfoDO.getCashAmount().negate());
}
}
//如果退回佣金等于0
if (residueAmount.compareTo(BigDecimal.ZERO) == 0) {
publisherWalletFlowVO.setYxjCashPledge(requirementsInfoDO.getCashAmount().negate());
} }
if (residueAmount.compareTo(BigDecimal.ZERO) == 0 if (residueAmount.compareTo(BigDecimal.ZERO) == -1) {
|| residueAmount.compareTo(BigDecimal.ZERO) == -1) {
publisherWalletFlowVO.setUserAccountId(userAccountId); publisherWalletFlowVO.setUserAccountId(userAccountId);
publisherWalletFlowVO.setOperateUserAccountId(userAccountId); publisherWalletFlowVO.setOperateUserAccountId(userAccountId);
publisherWalletFlowVO.setModeOfPayment(300); publisherWalletFlowVO.setModeOfPayment(300);
...@@ -1155,10 +1178,8 @@ public class RequirementsServiceImpl implements RequirementsService { ...@@ -1155,10 +1178,8 @@ public class RequirementsServiceImpl implements RequirementsService {
} }
if (requirementsInfoDO.getCashAmount().compareTo(BigDecimal.ZERO) != 0) { if (requirementsInfoDO.getCashAmount().compareTo(BigDecimal.ZERO) != 0) {
BigDecimal subtract1 = requirementsInfoDO.getCashAmount().subtract(publisherWalletFlowVO.getCashAmount()); BigDecimal subtract1 = requirementsInfoDO.getCashAmount().subtract(publisherWalletFlowVO.getCashAmount());
publisherWalletFlowVO.setYxjCashPledge(subtract1); publisherWalletFlowVO.setYxjCashPledge(subtract1.negate());
} }
//publisherWalletFlowVO.setYxjCashPledge(subtract.negate()); //publisherWalletFlowVO.setYxjCashPledge(subtract.negate());
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论