Browse Source

解决报错

dev_shibei_match
yinzuomei 5 years ago
parent
commit
d77bb61d27
  1. 1
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/topic/TopicService.java
  2. 22
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/topic/impl/TopicServiceImpl.java

1
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/topic/TopicService.java

@ -36,7 +36,6 @@ public interface TopicService {
* @Date 2020/9/15 18:12 * @Date 2020/9/15 18:12
**/ **/
List<TopicOriginInfoDTO> queryTopicOriginInfoList(String customerId, String dateId); List<TopicOriginInfoDTO> queryTopicOriginInfoList(String customerId, String dateId);
void topicDataCleaning(String customerId, String dateId);
/** /**
* @Description 查询话题创建者信息 * @Description 查询话题创建者信息
* @param topicIds * @param topicIds

22
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/topic/impl/TopicServiceImpl.java

@ -233,9 +233,10 @@ public class TopicServiceImpl implements TopicService {
List<ResiGroupTopicResultDTO> groupList = new LinkedList<>(); List<ResiGroupTopicResultDTO> groupList = new LinkedList<>();
for(Map.Entry<String,List<ResiGroupTopicResultDTO>> entry : gridGroupMap.entrySet()){ for(Map.Entry<String,List<ResiGroupTopicResultDTO>> entry : gridGroupMap.entrySet()){
if(null != entry.getValue() && entry.getValue().size() > NumConstant.ZERO) if(null != entry.getValue() && entry.getValue().size() > NumConstant.ZERO){
groupList.addAll(entry.getValue()); groupList.addAll(entry.getValue());
} }
}
//key -> groupId //key -> groupId
Map<String,GroupTopicData> groupTopicData = traverseGroupTopic(groupList,topicOperationMap); Map<String,GroupTopicData> groupTopicData = traverseGroupTopic(groupList,topicOperationMap);
@ -367,9 +368,10 @@ public class TopicServiceImpl implements TopicService {
List<ResiGroupTopicResultDTO> groupListBetweenTimeRange = new LinkedList<>(); List<ResiGroupTopicResultDTO> groupListBetweenTimeRange = new LinkedList<>();
for(Map.Entry<String,List<ResiGroupTopicResultDTO>> entryBetweenTimeRange : GridGroupMapBetweenTimeRange.entrySet()){ for(Map.Entry<String,List<ResiGroupTopicResultDTO>> entryBetweenTimeRange : GridGroupMapBetweenTimeRange.entrySet()){
if(null != entryBetweenTimeRange.getValue() && entryBetweenTimeRange.getValue().size() > NumConstant.ZERO) if(null != entryBetweenTimeRange.getValue() && entryBetweenTimeRange.getValue().size() > NumConstant.ZERO){
groupListBetweenTimeRange.addAll(entryBetweenTimeRange.getValue()); groupListBetweenTimeRange.addAll(entryBetweenTimeRange.getValue());
} }
}
List<ResiTopicOperationResultDTO> operationsBetweenTimeRange = List<ResiTopicOperationResultDTO> operationsBetweenTimeRange =
topicDao.selectTopicOperationRecordBetweenTimeRange(calendar.getTime(),targetDateCheck); topicDao.selectTopicOperationRecordBetweenTimeRange(calendar.getTime(),targetDateCheck);
@ -461,9 +463,9 @@ public class TopicServiceImpl implements TopicService {
* @date 2020.06.22 16:03 * @date 2020.06.22 16:03
**/ **/
Map<String,GroupTopicData> traverseGroupTopic(List<ResiGroupTopicResultDTO> groups, Map<String,List<ResiTopicOperationResultDTO>> topicOperationMap){ Map<String,GroupTopicData> traverseGroupTopic(List<ResiGroupTopicResultDTO> groups, Map<String,List<ResiTopicOperationResultDTO>> topicOperationMap){
if(null == groups || groups.size() < NumConstant.ONE) if(null == groups || groups.size() < NumConstant.ONE){
return null; return null;
}
Map<String , GroupTopicData> groupTopicStatistical = new HashMap<>(); Map<String , GroupTopicData> groupTopicStatistical = new HashMap<>();
groups.forEach(group -> { groups.forEach(group -> {
@ -491,7 +493,9 @@ public class TopicServiceImpl implements TopicService {
//}else{ //}else{
for (ResiTopicResultDTO topic : group.getTopics()) { for (ResiTopicResultDTO topic : group.getTopics()) {
if(StringUtils.isBlank(topic.getTopicId())) continue; if(StringUtils.isBlank(topic.getTopicId())){
continue;
}
if (StringUtils.equals(NumConstant.ONE_STR, topic.getIncrFlag())) { if (StringUtils.equals(NumConstant.ONE_STR, topic.getIncrFlag())) {
groupTopicData.setTopicIncr(groupTopicData.getTopicIncr() + NumConstant.ONE); groupTopicData.setTopicIncr(groupTopicData.getTopicIncr() + NumConstant.ONE);
} }
@ -980,9 +984,10 @@ public class TopicServiceImpl implements TopicService {
List<ResiGroupTopicResultDTO> groupList = new LinkedList<>(); List<ResiGroupTopicResultDTO> groupList = new LinkedList<>();
for(Map.Entry<String,List<ResiGroupTopicResultDTO>> entry : gridGroupMap.entrySet()){ for(Map.Entry<String,List<ResiGroupTopicResultDTO>> entry : gridGroupMap.entrySet()){
if(null != entry.getValue() && entry.getValue().size() > NumConstant.ZERO) if(null != entry.getValue() && entry.getValue().size() > NumConstant.ZERO){
groupList.addAll(entry.getValue()); groupList.addAll(entry.getValue());
} }
}
//key -> groupId //key -> groupId
Map<String,GroupTopicData> groupTopicData = traverseGroupTopic(groupList,topicOperationMap); Map<String,GroupTopicData> groupTopicData = traverseGroupTopic(groupList,topicOperationMap);
@ -1148,9 +1153,10 @@ public class TopicServiceImpl implements TopicService {
List<ResiGroupTopicResultDTO> groupListBetweenTimeRange = new LinkedList<>(); List<ResiGroupTopicResultDTO> groupListBetweenTimeRange = new LinkedList<>();
for(Map.Entry<String,List<ResiGroupTopicResultDTO>> entryBetweenTimeRange : GridGroupMapBetweenTimeRange.entrySet()){ for(Map.Entry<String,List<ResiGroupTopicResultDTO>> entryBetweenTimeRange : GridGroupMapBetweenTimeRange.entrySet()){
if(null != entryBetweenTimeRange.getValue() && entryBetweenTimeRange.getValue().size() > NumConstant.ZERO) if(null != entryBetweenTimeRange.getValue() && entryBetweenTimeRange.getValue().size() > NumConstant.ZERO){
groupListBetweenTimeRange.addAll(entryBetweenTimeRange.getValue()); groupListBetweenTimeRange.addAll(entryBetweenTimeRange.getValue());
} }
}
List<ResiTopicOperationResultDTO> operationsBetweenTimeRange = List<ResiTopicOperationResultDTO> operationsBetweenTimeRange =
topicDao.selectTopicOperationRecordBetweenTimeRange(calendar.getTime(),targetDate); topicDao.selectTopicOperationRecordBetweenTimeRange(calendar.getTime(),targetDate);
@ -1266,9 +1272,9 @@ public class TopicServiceImpl implements TopicService {
} }
/** /**
* @return java.util.List<com.epmet.dto.topic.TopicOriginInfoDTO>
* @param customerId * @param customerId
* @param dateId * @param dateId
* @return java.util.List<com.epmet.dto.topic.TopicOriginInfoDTO>
* @author yinzuomei * @author yinzuomei
* @description 根据日期查询resi_topic_operation返回所有对话体的操作记录 * @description 根据日期查询resi_topic_operation返回所有对话体的操作记录
* @Date 2020/9/15 18:13 * @Date 2020/9/15 18:13

Loading…
Cancel
Save