Commit 8cb3d7b0 by 王璐琦

fix(daily-report): 修正升级数统计逻辑和小计标签文本

- 将车衣及精品升级数按主订单维度统计,避免重复计数
- 修改销售、交付、售后小计名称为“合计”,统一文本表达
- 修复售后总交易金额显示为空的问题,改为正确显示金额
1 parent 260c66a7
......@@ -603,7 +603,8 @@ public class DailyReportDataService {
monthFilmUpgradeCount++;
filmCustomerPhones.add(customerPhone);
}
// 车衣(含改色膜)和精品:逐子订单计数
// 车衣(含改色膜)和精品:逐子订单计数,升级数按主订单维度
boolean orderHasUpgrade = false;
for (GoodsSubOrderDTO subOrder : order.getSubOrderList()) {
if (subOrder.getStatus() == null
|| !Objects.equals(RefundGoodsSubOrderStatusEnum.NOT_REFUNDED.getValue(), subOrder.getStatus())) {
......@@ -622,6 +623,9 @@ public class DailyReportDataService {
if (matchesBoutique) {
monthBoutiqueUpgradeCount++;
}
orderHasUpgrade = true;
}
if (orderHasUpgrade) {
monthUpgradeCount++;
}
}
......
......@@ -255,7 +255,7 @@ public class DailyReportExcelService {
private Map<String, String> buildSalesSubtotalRow(List<Map<String, String>> rows) {
Map<String, String> row = new LinkedHashMap<>();
row.put("departmentName", "销售小计");
row.put("departmentName", "合计");
row.put("list_salesConsultant", "");
row.put("list_largeOrderCountOfToday", sumIntText(rows, "list_largeOrderCountOfToday"));
row.put("list_largeOrderReachGroupCountOfToday", sumIntText(rows, "list_largeOrderReachGroupCountOfToday"));
......@@ -273,7 +273,7 @@ public class DailyReportExcelService {
private Map<String, String> buildDeliverySubtotalRow(List<Map<String, String>> rows) {
Map<String, String> row = new LinkedHashMap<>();
row.put("departmentName", "交付小计");
row.put("departmentName", "合计");
row.put("list_deliverySpecialist", "");
row.put("list_deliverieCountOfToday", sumIntText(rows, "list_deliverieCountOfToday"));
row.put("list_referralCountOfToday", sumIntText(rows, "list_referralCountOfToday"));
......@@ -295,7 +295,7 @@ public class DailyReportExcelService {
private Map<String, String> buildAfterSaleSubtotalRow(List<Map<String, String>> rows) {
Map<String, String> row = new LinkedHashMap<>();
row.put("departmentName", "售后小计");
row.put("departmentName", "合计");
row.put("list_sa", "");
row.put("list_firstMaintenanceCountOfToday", sumIntText(rows, "list_firstMaintenanceCountOfToday"));
row.put("list_accidentVehicleCountOfToday", sumIntText(rows, "list_accidentVehicleCountOfToday"));
......@@ -357,7 +357,7 @@ public class DailyReportExcelService {
row.put("list_monthDeliveryCount", sumIntText(rows, "list_monthDeliveryCount"));
BigDecimal monthTotalOutput = sumDecimal(rows, "list_monthTotalOutput");
row.put("list_monthTotalOutput", formatAmount(monthTotalOutput));
row.put("afterSalesTransactionAmount", "");
row.put("afterSalesTransactionAmount", formatAmount(monthTotalOutput));
return row;
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!