|
|
@ -6,7 +6,6 @@ import cn.hutool.core.util.NumberUtil;
|
|
|
|
import com.baiye.constant.DefaultNumberConstants;
|
|
|
|
import com.baiye.constant.DefaultNumberConstants;
|
|
|
|
import com.baiye.constant.SourceLabelConstants;
|
|
|
|
import com.baiye.constant.SourceLabelConstants;
|
|
|
|
import com.baiye.feign.UserClient;
|
|
|
|
import com.baiye.feign.UserClient;
|
|
|
|
import com.baiye.model.dto.HomePageReportDTO;
|
|
|
|
|
|
|
|
import com.baiye.module.dao.ClueJpa;
|
|
|
|
import com.baiye.module.dao.ClueJpa;
|
|
|
|
import com.baiye.module.dao.ClueTalkRepository;
|
|
|
|
import com.baiye.module.dao.ClueTalkRepository;
|
|
|
|
import com.baiye.module.dao.ReportTokerCallRepository;
|
|
|
|
import com.baiye.module.dao.ReportTokerCallRepository;
|
|
|
@ -60,7 +59,10 @@ public class ReportSync {
|
|
|
|
public List<ReportToker> dealData(List<ClueTalk> clueTalks) {
|
|
|
|
public List<ReportToker> dealData(List<ClueTalk> clueTalks) {
|
|
|
|
List<ReportToker> list = new ArrayList<>();
|
|
|
|
List<ReportToker> list = new ArrayList<>();
|
|
|
|
//按人员id分组
|
|
|
|
//按人员id分组
|
|
|
|
HashMap<Long, List<ClueTalk>> mapByUserId = new HashMap<>(clueTalks.stream().collect(Collectors.groupingBy(ClueTalk::getMemberId, Collectors.toList())));
|
|
|
|
// HashMap<Long, List<ClueTalk>> mapByUserId = new HashMap<>(clueTalks.stream().collect(Collectors.groupingBy(ClueTalk::getMemberId, Collectors.toList())));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
HashMap<Long, List<ClueTalk>> mapByUserId = new HashMap<>(clueTalks.stream()
|
|
|
|
|
|
|
|
.filter(item -> item.getMemberId() != null).collect(Collectors.groupingBy(ClueTalk::getMemberId)));
|
|
|
|
Set<Long> userIds = mapByUserId.keySet();
|
|
|
|
Set<Long> userIds = mapByUserId.keySet();
|
|
|
|
Map<Long, String> userNameList = userClient.findById(userIds);
|
|
|
|
Map<Long, String> userNameList = userClient.findById(userIds);
|
|
|
|
for (Long memberId : mapByUserId.keySet()) {
|
|
|
|
for (Long memberId : mapByUserId.keySet()) {
|
|
|
|