Commit 303b93e7 by 张富康

chore(logging): 添加详细日志输出以便调试和监控

- 记录鸿蒙商户列表的完整JSON信息
- 打印A036接口请求参数及响应结果
- 输出产值大于0的手机号列表
- 记录账户中心北森员工信息及筛选结果
- 打印A075接口请求参数及响应结果
- 记录A061接口请求参数及响应结果
- 输出渗透率Map内容
- 记录课程成绩最高分的考试ID和详细信息
1 parent b6a1f5b8
...@@ -74,7 +74,7 @@ public class DownloadReportService { ...@@ -74,7 +74,7 @@ public class DownloadReportService {
carBrandProvinceRequestDTO.setFirstBrandIdList(Collections.singletonList(brandId)); carBrandProvinceRequestDTO.setFirstBrandIdList(Collections.singletonList(brandId));
RpcResponse<List<MerchantProvinceDTO>> merchantListByBrandIdsProvince = merchantRemote.findMerchantListByBrandIdsProvince(carBrandProvinceRequestDTO); RpcResponse<List<MerchantProvinceDTO>> merchantListByBrandIdsProvince = merchantRemote.findMerchantListByBrandIdsProvince(carBrandProvinceRequestDTO);
List<MerchantProvinceDTO> merchantListByBrandIdsProvinceResult = merchantListByBrandIdsProvince.getResult(); List<MerchantProvinceDTO> merchantListByBrandIdsProvinceResult = merchantListByBrandIdsProvince.getResult();
log.info("鸿蒙商户-数量: {}", merchantListByBrandIdsProvinceResult.size()); log.info("鸿蒙-商户: {}", JSONUtil.toJsonStr(merchantListByBrandIdsProvinceResult));
if (CollUtil.isEmpty(merchantListByBrandIdsProvinceResult)) { if (CollUtil.isEmpty(merchantListByBrandIdsProvinceResult)) {
return result; return result;
} }
...@@ -92,7 +92,9 @@ public class DownloadReportService { ...@@ -92,7 +92,9 @@ public class DownloadReportService {
dataBizQueryParamsA036DTO.setExts("staffIds"); dataBizQueryParamsA036DTO.setExts("staffIds");
dataBizQueryParamsA036DTO.setDateType(4); dataBizQueryParamsA036DTO.setDateType(4);
String jsonBodyA036 = JSONUtil.toJsonStr(dataBizQueryParamsA036DTO); String jsonBodyA036 = JSONUtil.toJsonStr(dataBizQueryParamsA036DTO);
log.info("A036-参数: {}", jsonBodyA036);
DataResp<List<DataBusinessDTO>> listDataRespA036 = getDataStatsService.getListDataResp(jsonBodyA036); DataResp<List<DataBusinessDTO>> listDataRespA036 = getDataStatsService.getListDataResp(jsonBodyA036);
log.info("A036-结果: {}", JSONUtil.toJsonStr(listDataRespA036));
List<DataBusinessDTO> contentA036 = listDataRespA036.getContent(); List<DataBusinessDTO> contentA036 = listDataRespA036.getContent();
if (CollUtil.isEmpty(contentA036)) { if (CollUtil.isEmpty(contentA036)) {
return result; return result;
...@@ -106,12 +108,14 @@ public class DownloadReportService { ...@@ -106,12 +108,14 @@ public class DownloadReportService {
.collect(Collectors.toMap(DataBusinessDTO::getStaffPhone, DataBusinessDTO::getStaffId)); .collect(Collectors.toMap(DataBusinessDTO::getStaffPhone, DataBusinessDTO::getStaffId));
// 获取产值大于0的手机号 // 获取产值大于0的手机号
List<String> contentMobileList = new ArrayList<>(staffPhoneMap.keySet()); List<String> contentMobileList = new ArrayList<>(staffPhoneMap.keySet());
log.info("获取产值大于0的手机号: {}", JSONUtil.toJsonStr(contentMobileList));
if (CollUtil.isEmpty(contentMobileList)) { if (CollUtil.isEmpty(contentMobileList)) {
return result; return result;
} }
// 查询账户中心北森员工信息 // 查询账户中心北森员工信息
RpcResponse<List<BeisenEmployeeInfoDTO>> listRpcResponse = merchantUserRemote.selectByPhones(contentMobileList); RpcResponse<List<BeisenEmployeeInfoDTO>> listRpcResponse = merchantUserRemote.selectByPhones(contentMobileList);
List<BeisenEmployeeInfoDTO> listRpcResponseResult = listRpcResponse.getResult(); List<BeisenEmployeeInfoDTO> listRpcResponseResult = listRpcResponse.getResult();
log.info("账户中心北森员工信息: {}", JSONUtil.toJsonStr(listRpcResponseResult));
if (CollUtil.isEmpty(listRpcResponseResult)) { if (CollUtil.isEmpty(listRpcResponseResult)) {
return result; return result;
} }
...@@ -123,6 +127,7 @@ public class DownloadReportService { ...@@ -123,6 +127,7 @@ public class DownloadReportService {
.filter(beisenEmployeeInfoDTO -> DateUtil.between(beisenEmployeeInfoDTO.getEntryDate(), previousQuarter.getEndDate(), DateUnit.DAY, false) > 29 .filter(beisenEmployeeInfoDTO -> DateUtil.between(beisenEmployeeInfoDTO.getEntryDate(), previousQuarter.getEndDate(), DateUnit.DAY, false) > 29
&& beisenEmployeeInfoDTO.getZzStatus() == 0) && beisenEmployeeInfoDTO.getZzStatus() == 0)
.collect(Collectors.toList()); .collect(Collectors.toList());
log.info("入职天数大于30天的员工,且未离职: {}", JSONUtil.toJsonStr(listRpcResponseResult));
if (CollUtil.isEmpty(listRpcResponseResult)) { if (CollUtil.isEmpty(listRpcResponseResult)) {
return result; return result;
} }
...@@ -148,7 +153,9 @@ public class DownloadReportService { ...@@ -148,7 +153,9 @@ public class DownloadReportService {
dataBizQueryParamsA075DTO.setStaffIds(StrUtil.join(",", staffIds)); dataBizQueryParamsA075DTO.setStaffIds(StrUtil.join(",", staffIds));
dataBizQueryParamsA075DTO.setDateType(4); dataBizQueryParamsA075DTO.setDateType(4);
String jsonBodyA075 = JSONUtil.toJsonStr(dataBizQueryParamsA075DTO); String jsonBodyA075 = JSONUtil.toJsonStr(dataBizQueryParamsA075DTO);
log.info("A075-参数: {}", jsonBodyA075);
DataResp<List<DataBusinessDTO>> listDataRespA075 = getDataStatsService.getListDataResp(jsonBodyA075); DataResp<List<DataBusinessDTO>> listDataRespA075 = getDataStatsService.getListDataResp(jsonBodyA075);
log.info("A075-结果: {}", JSONUtil.toJsonStr(listDataRespA075));
List<DataBusinessDTO> contentA075 = listDataRespA075.getContent(); List<DataBusinessDTO> contentA075 = listDataRespA075.getContent();
// 应触客数 A061 // 应触客数 A061
...@@ -162,7 +169,9 @@ public class DownloadReportService { ...@@ -162,7 +169,9 @@ public class DownloadReportService {
dataBizQueryParamsA061DTO.setStaffIds(StrUtil.join(",", staffIds)); dataBizQueryParamsA061DTO.setStaffIds(StrUtil.join(",", staffIds));
dataBizQueryParamsA061DTO.setDateType(4); dataBizQueryParamsA061DTO.setDateType(4);
String jsonBodyA061 = JSONUtil.toJsonStr(dataBizQueryParamsA061DTO); String jsonBodyA061 = JSONUtil.toJsonStr(dataBizQueryParamsA061DTO);
log.info("A061-参数: {}", jsonBodyA061);
DataResp<List<DataBusinessDTO>> listDataRespA061 = getDataStatsService.getListDataResp(jsonBodyA061); DataResp<List<DataBusinessDTO>> listDataRespA061 = getDataStatsService.getListDataResp(jsonBodyA061);
log.info("A061-结果: {}", JSONUtil.toJsonStr(listDataRespA061));
List<DataBusinessDTO> contentA061 = listDataRespA061.getContent(); List<DataBusinessDTO> contentA061 = listDataRespA061.getContent();
// 渗透率 = 订单成交数 / 应触客数 // 渗透率 = 订单成交数 / 应触客数
...@@ -198,11 +207,13 @@ public class DownloadReportService { ...@@ -198,11 +207,13 @@ public class DownloadReportService {
} }
} }
} }
log.info("渗透率Map: {}", JSONUtil.toJsonStr(penetrationRateMap));
// 查询课程成绩 // 查询课程成绩
// 线上 499c2215-5023-42c7-a3dd-f09feb5cdd14 // 线上 499c2215-5023-42c7-a3dd-f09feb5cdd14
String examinationId = OrePropertyConfigurer.getProperty("examination_id", String.class, "499c2215-5023-42c7-a3dd-f09feb5cdd14"); String examinationId = OrePropertyConfigurer.getProperty("examination_id", String.class, "499c2215-5023-42c7-a3dd-f09feb5cdd14");
List<BeiSenExaminationTrainees> beiSenExaminationTrainees = beiSenExaminationTraineesMapper.queryTopPoint(examinationId, userIDs); List<BeiSenExaminationTrainees> beiSenExaminationTrainees = beiSenExaminationTraineesMapper.queryTopPoint(examinationId, userIDs);
log.info("考试id:{},课程成绩最高分: {}", examinationId, JSONUtil.toJsonStr(beiSenExaminationTrainees));
Map<Integer, BeiSenExaminationTrainees> beiSenExaminationTraineesMap = beiSenExaminationTrainees.stream().collect(Collectors.toMap(BeiSenExaminationTrainees::getUserId, Function.identity())); Map<Integer, BeiSenExaminationTrainees> beiSenExaminationTraineesMap = beiSenExaminationTrainees.stream().collect(Collectors.toMap(BeiSenExaminationTrainees::getUserId, Function.identity()));
// 组装表格 // 组装表格
List<ReportExcelDateInfoDTO> dataList = new ArrayList<>(); List<ReportExcelDateInfoDTO> dataList = new ArrayList<>();
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!