Commit 7ec88b4c by 王璐琦

feat(dailyReport): 优化日报填报校验与延保数据统计逻辑

- 在StaffDailyReportController中新增调用hasDailyReportRecord接口判断昨日日报是否已填报
- rpc-daily-report模块新增接口及实现支持查询是否存在日报填报记录
- rpc-daily-report模块完善DailyReportRecordService的hasDailyReportRecord方法实现
- rpc-daily-report-api增加hasDailyReportRecord远程接口定义
- rpc-daily-report模块调整pushDailyReportData调用逻辑优化异步推送代码
- rpc-dj-daily-report模块ExtendedWarranty统计方法中统一新增基础品牌HUAWEI问界ID配置
- 统计逻辑中调整销售类型判断条件,同时增加多个延保和柔性工单品类的代码兼容
- 优化客户打标、触客、到店统计逻辑,完善成交金额及产品品名统计合计
- GoodsOrderMapper.xml新增字段stand_no映射,丰富订单数据维度
- 修复统计报表合计行DepartmentName与DeliverySpecialist字段赋值问题
- 调整部分注释及日志,提升代码可读性和维护性
1 parent 6e6b0ec6
...@@ -63,4 +63,9 @@ public interface DailyReportRecordRemote { ...@@ -63,4 +63,9 @@ public interface DailyReportRecordRemote {
@ApiParam(name="dailyReportRecordDTO",notes="查询条件",dataType= ApiParam.DataTypeEnum.OBJECT,required=true) @ApiParam(name="dailyReportRecordDTO",notes="查询条件",dataType= ApiParam.DataTypeEnum.OBJECT,required=true)
@ApiResponse("推送结果") @ApiResponse("推送结果")
RpcResponse<Boolean> pushDailyReportData(DailyReportRecordDTO dailyReportRecordDTO); RpcResponse<Boolean> pushDailyReportData(DailyReportRecordDTO dailyReportRecordDTO);
@ApiMethod("查询指定商户指定场景指定日期是否存在填报记录")
@ApiParam(name="dailyReportRecordDTO",notes="查询条件(merchantId/sceneType/reportDate)",dataType= ApiParam.DataTypeEnum.OBJECT,required=true)
@ApiResponse("是否存在填报记录")
RpcResponse<Boolean> hasDailyReportRecord(DailyReportRecordDTO dailyReportRecordDTO);
} }
...@@ -127,4 +127,14 @@ public class DailyReportRecordRemoteImpl implements DailyReportRecordRemote { ...@@ -127,4 +127,14 @@ public class DailyReportRecordRemoteImpl implements DailyReportRecordRemote {
return RpcResponse.error(e); return RpcResponse.error(e);
} }
} }
@Override
public RpcResponse<Boolean> hasDailyReportRecord(DailyReportRecordDTO dailyReportRecordDTO) {
try{
return RpcResponse.success(dailyReportRecordService.hasDailyReportRecord(dailyReportRecordDTO));
}catch(RpcServiceException e){
log.error(e.getMessage(),e);
return RpcResponse.error(e);
}
}
} }
...@@ -1401,7 +1401,7 @@ public class DailyReportRecordService { ...@@ -1401,7 +1401,7 @@ public class DailyReportRecordService {
dailyReportRecordDTO.setMerchantId(existing.getMerchantId()); dailyReportRecordDTO.setMerchantId(existing.getMerchantId());
dailyReportRecordDTO.setSceneType(existing.getSceneType()); dailyReportRecordDTO.setSceneType(existing.getSceneType());
asyncPushDailyReportData(dailyReportRecordDTO); //TODO 修改群推送逻辑 asyncPushDailyReportData(dailyReportRecordDTO);
log.info("pushDailyReport success, id={}", dailyReportRecordId); log.info("pushDailyReport success, id={}", dailyReportRecordId);
return Boolean.TRUE; return Boolean.TRUE;
...@@ -1414,6 +1414,17 @@ public class DailyReportRecordService { ...@@ -1414,6 +1414,17 @@ public class DailyReportRecordService {
} }
} }
public Boolean hasDailyReportRecord(DailyReportRecordDTO dailyReportRecordDTO) {
Example example = new Example(DailyReportRecord.class);
example.createCriteria()
.andEqualTo("deletedFlag", DeleteFlagEnum.N.getValue())
.andEqualTo("merchantId", dailyReportRecordDTO.getMerchantId())
.andEqualTo("sceneType", dailyReportRecordDTO.getSceneType())
.andEqualTo("templateType", dailyReportRecordDTO.getTemplateType())
.andEqualTo("reportDate", dailyReportRecordDTO.getReportDate());
return CollectionUtils.isNotEmpty(dailyReportRecordMapper.selectByExample(example));
}
/** /**
* 华为子品牌字段映射:(个人大定触客/进群数-轻改, 个人售后触客数-轻改, 个人交付引荐数-轻改, 实际售前触客数-延保, 实际售后触客数-延保, 未触客返店人数-延保) * 华为子品牌字段映射:(个人大定触客/进群数-轻改, 个人售后触客数-轻改, 个人交付引荐数-轻改, 实际售前触客数-延保, 实际售后触客数-延保, 未触客返店人数-延保)
*/ */
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!