diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/QualityDeliverEntity.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/QualityDeliverEntity.java index 55f75c767..79824d951 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/QualityDeliverEntity.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/QualityDeliverEntity.java @@ -639,6 +639,11 @@ public class QualityDeliverEntity extends TenantEntity { */ @ApiModelProperty(value = "上楼费成本") private BigDecimal apstairsCost; + /** + * 平移米数 + */ + @ApiModelProperty(value = "平移米数") + private Integer moveNumber; /** * 平移费成本 */ diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/receiver/report/DeliverFinishReportListener.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/receiver/report/DeliverFinishReportListener.java index 7e624de0a..9eafa08a8 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/receiver/report/DeliverFinishReportListener.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/receiver/report/DeliverFinishReportListener.java @@ -207,6 +207,7 @@ public class DeliverFinishReportListener implements ReportService { if (ObjectUtil.isEmpty(rule)) { continue; } + // 计算配送成本 if (CollUtil.isNotEmpty(priceList)) { Map priceMap = priceList.stream().collect(Collectors.toMap(ExpenseDispatchPriceCategoryVO::getCategoryId, v -> v)); // 车的总运费 用于计算是否触发保底 @@ -298,6 +299,7 @@ public class DeliverFinishReportListener implements ReportService { // 上楼费成本 = 上楼费单价 * 上楼层数 * 签收件数 QualityDeliverEntity qualityDeliverEntity1 = valueMap.get(entity.getId()); if (ObjectUtil.isNotEmpty(stairsNumber) && StrUtil.isNotEmpty(stairsCharge)) { + qualityDeliverEntity1.setStairsNumber(stairsNumber); qualityDeliverEntity1.setApstairsCost(NumberUtil.mul(stairsNumber, new BigDecimal(stairsCharge), signNum)); } // 分货费成本 = 分货费单价 * 签收件数 @@ -306,6 +308,7 @@ public class DeliverFinishReportListener implements ReportService { } // 平移费成本 = 平移费单价 * 平移米数 * 签收件数 if (StrUtil.isNotEmpty(translationFee)) { + qualityDeliverEntity1.setMoveNumber(translationNumber); qualityDeliverEntity1.setMoveCost(NumberUtil.mul(translationNumber, new BigDecimal(translationFee), signNum)); } // 装卸费成本 = 装卸费单价 * 签收件数 diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/receiver/report/PlanReportListener.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/receiver/report/PlanReportListener.java index 2f205cd87..862c5cf1b 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/receiver/report/PlanReportListener.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/receiver/report/PlanReportListener.java @@ -90,7 +90,7 @@ public class PlanReportListener implements ReportService { } else { // 没有查询到,延迟30秒重新推送 factoryDataClient.sendMessage(SendMsg.builder() - .exchange(FanoutConstants.distribution.DeliveryAndPlan.EXCHANGE) + .exchange(FanoutConstants.distribution.DeliveryAndPlan.EXCHANGE_DELAY) .routingKey(null) .message(msg) .delay(30000)