Browse Source

2024年11月25日17:29:17

纪新园 1 year ago
parent
commit
6cdac157b0

+ 10 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/fee/service/impl/FeeCenterServiceImpl.java

@@ -1275,6 +1275,16 @@ public class FeeCenterServiceImpl extends ServiceImpl<FeeCenterMapper, FeeCenter
 						feeCenter.setPodEnName(agent.getPodEnName());
 					}
 				}
+				if (!bCorpsList.isEmpty()){
+					BCorps bCorps = bCorpsList.stream().filter(e-> e.getId().equals(feeCenter.getCorpId())).findFirst().orElse(null);
+					if (bCorps != null){
+						feeCenter.setShortName(bCorps.getShortName());
+					}
+					BCorps bCorps1 = bCorpsList.stream().filter(e-> e.getId().equals(feeCenter.getBillCorpId())).findFirst().orElse(null);
+					if (bCorps1 != null){
+						feeCenter.setBillCorpEnName(bCorps1.getShortName());
+					}
+				}
 				if (feeCenter.getId() == null) {
 					feeCenter.setCreateTime(new Date());
 					feeCenter.setCreateUser(AuthUtil.getUserId());

+ 1 - 1
blade-service/blade-los/src/main/java/org/springblade/los/trade/service/impl/AgentServiceImpl.java

@@ -764,7 +764,7 @@ public class AgentServiceImpl extends ServiceImpl<AgentMapper, Agent> implements
 			}
 			filesCenterService.saveOrUpdateBatch(agent.getFilesCenterList());
 		}
-		if (agent.getGoodsValue().compareTo(agent.getPrepaidAmount()) < 0) {
+		if (ObjectUtils.isNotNull(agent.getGoodsValue()) && agent.getGoodsValue().compareTo(agent.getPrepaidAmount()) < 0) {
 			throw new RuntimeException("预付款不能大于货值");
 		}
 		return R.data(agent);

+ 6 - 6
blade-service/blade-sales-part/src/main/java/org/springblade/salesPart/shoppingCart/service/impl/ShoppingCartServiceImpl.java

@@ -294,7 +294,7 @@ public class ShoppingCartServiceImpl extends ServiceImpl<ShoppingCartMapper, PjS
 						order.setTotalMoney(totalMoney);
 
 						if (order.getGoodsTotalNum().compareTo(new BigDecimal(1)) == 0) {
-							String freight = sysClient.getParamService("freight");
+							String freight = sysClient.getParamServiceDWT("freight",finalCorpsDesc.getTenantId());
 							if (ObjectUtils.isNotNull(freight)) {
 								try {
 									BigDecimal freightAmount = new BigDecimal(freight);
@@ -309,7 +309,7 @@ public class ShoppingCartServiceImpl extends ServiceImpl<ShoppingCartMapper, PjS
 							order.setTotalMoney(totalMoney);
 							order.setFreight(new BigDecimal(5));*/
 						}
-						amount = amount.add(totalMoney);
+						amount = amount.add(order.getTotalMoney());
 //						order.setPaymentAmountTl(totalMoney);
 						order.setSharedCompanyId(shoppingCartList.get(0).getSharedCompanyId());
 						order.setSharedCompanyName(shoppingCartList.get(0).getSharedCompanyName());
@@ -491,7 +491,7 @@ public class ShoppingCartServiceImpl extends ServiceImpl<ShoppingCartMapper, PjS
 						order.setTotalMoney(totalMoney);
 
 						if (order.getGoodsTotalNum().compareTo(new BigDecimal(1)) == 0) {
-							String freight = sysClient.getParamService("freight");
+							String freight = sysClient.getParamServiceDWT("freight",finalCorpsDesc.getTenantId());
 							if (ObjectUtils.isNotNull(freight)) {
 								try {
 									BigDecimal freightAmount = new BigDecimal(freight);
@@ -506,7 +506,7 @@ public class ShoppingCartServiceImpl extends ServiceImpl<ShoppingCartMapper, PjS
 							order.setTotalMoney(totalMoney);
 							order.setFreight(new BigDecimal(5));*/
 						}
-						amount = amount.add(totalMoney);
+						amount = amount.add(order.getTotalMoney());
 						order.setSharedCompanyId(shoppingCartList.get(0).getSharedCompanyId());
 						order.setSharedCompanyName(shoppingCartList.get(0).getSharedCompanyName());
 					}
@@ -693,7 +693,7 @@ public class ShoppingCartServiceImpl extends ServiceImpl<ShoppingCartMapper, PjS
 						order.setTotalMoney(totalMoney);
 
 						if (order.getGoodsTotalNum().compareTo(new BigDecimal(1)) == 0) {
-							String freight = sysClient.getParamService("freight");
+							String freight = sysClient.getParamServiceDWT("freight",finalCorpsDesc.getTenantId());
 							if (ObjectUtils.isNotNull(freight)) {
 								try {
 									BigDecimal freightAmount = new BigDecimal(freight);
@@ -708,7 +708,7 @@ public class ShoppingCartServiceImpl extends ServiceImpl<ShoppingCartMapper, PjS
 							order.setTotalMoney(totalMoney);
 							order.setFreight(new BigDecimal(5));*/
 						}
-						amount = amount.add(totalMoney);
+						amount = amount.add(order.getTotalMoney());
 						order.setPaymentDate(new Date());
 						order.setActualPaymentStatus(1);
 						order.setPaymentAmountTl(totalMoney);