Commit 4f4ca8ce authored by 332784038@qq.com's avatar 332784038@qq.com

Merge branch 'master-fix' into dev

parents ab2626cc 8744a59c
......@@ -2450,11 +2450,12 @@ public class OrderQueryServiceImpl implements OrderQueryService {
for (OrderItemDO orderItemDO : orderItemDOList) {
// 判断品名是否入仓
boolean isWarehouseIn = Objects.nonNull(orderItemDO.getWarehouseInInfoVO()) && orderItemDO.getWarehouseInInfoVO().getCartonsNum() > 0;
BigDecimal seaFreight = orderItemDO.getSeaFreight().setScale(0, RoundingMode.HALF_UP);
BigDecimal receivableSeaFreight = orderItemDO.getReceivableSeaFreight().compareTo(BigDecimal.ZERO) == 0 ? seaFreight : orderItemDO.getReceivableSeaFreight();
BigDecimal clearanceFreight = orderItemDO.getClearanceFreight().setScale(0, RoundingMode.HALF_UP);
BigDecimal receivableClearanceFreight = orderItemDO.getReceivableClearanceFreight().compareTo(BigDecimal.ZERO) == 0 ? clearanceFreight : orderItemDO.getReceivableClearanceFreight();
if (isWarehouseIn) {
BigDecimal seaFreight = Objects.nonNull(orderItemDO.getSeaFreight()) ? orderItemDO.getSeaFreight().setScale(0, RoundingMode.HALF_UP) : BigDecimal.ZERO;
BigDecimal receivableSeaFreight = Objects.nonNull(orderItemDO.getReceivableSeaFreight()) ? (orderItemDO.getReceivableSeaFreight().compareTo(BigDecimal.ZERO) == 0 ? seaFreight : orderItemDO.getReceivableSeaFreight()) : BigDecimal.ZERO;
BigDecimal clearanceFreight = Objects.nonNull(orderItemDO.getClearanceFreight()) ? orderItemDO.getClearanceFreight().setScale(0, RoundingMode.HALF_UP) : BigDecimal.ZERO;
BigDecimal receivableClearanceFreight = Objects.nonNull(orderItemDO.getReceivableClearanceFreight()) ? (orderItemDO.getReceivableClearanceFreight().compareTo(BigDecimal.ZERO) == 0 ? clearanceFreight : orderItemDO.getReceivableClearanceFreight()) : BigDecimal.ZERO;
Long freightCurrencyId = Long.parseLong(String.valueOf(orderItemDO.getSeaFreightCurrency()));
ExchangeRateRespDTO collectFreightRateRespDTO = currencyApi.getCurrencyRate(freightCurrencyId, collectFreightFeeId);
ExchangeRateRespDTO freightTotalFeeRateRespDTO = currencyApi.getCurrencyRate(freightCurrencyId, collectTotalFeeId);// 运费总费用汇率计算
......@@ -2790,9 +2791,7 @@ public class OrderQueryServiceImpl implements OrderQueryService {
// 运费优惠分组
StringBuilder discountFreightFeeGroup = new StringBuilder();
List<FeeGroupDto> discountFreightFeeGroupDtoList = new ArrayList<>();
this.
convertFeeGroup(currencyRespDTOMap, totalReceivableFreightFeeGroupDtoMap, totalNetReceiptsFreightFeeGroupDtoMap, discountFreightFeeGroupDtoList, discountFreightFeeGroup);
this.convertFeeGroup(currencyRespDTOMap, totalReceivableFreightFeeGroupDtoMap, totalNetReceiptsFreightFeeGroupDtoMap, discountFreightFeeGroupDtoList, discountFreightFeeGroup);
summaryDto.setDiscountFreightFeeGroupDtoList(discountFreightFeeGroupDtoList);
summaryDto.setDiscountFreightFeeGroup(discountFreightFeeGroup.toString());
// 运费换算成目的地设置的货币单位的总应收、总实收、总优惠
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment