|
@@ -520,13 +520,14 @@ public class CmBehaviorRecordServiceImpl implements CmBehaviorRecordService {
|
|
|
List<String> recodeTouristId = recordMapper.getRecodeTouristId(format);
|
|
|
if (null != recodeTouristId && recodeTouristId.size() > 0) {
|
|
|
// 网站中每个touristId有多个用户
|
|
|
- Map<String, Integer> cuxTouris = recordMapper.getCuxTouris(format);
|
|
|
+ List<CmBehaviorRecordPo> cuxTourist = recordMapper.getCuxTourist(format);
|
|
|
// 游客对应用户信息
|
|
|
List<CmBehaviorTouristInfoPo> touristInfo = recordMapper.getTouristInfo(format, recodeTouristId);
|
|
|
if (null != touristInfo) {
|
|
|
for (String touristId : recodeTouristId) {
|
|
|
// 用户个数
|
|
|
- num = null == cuxTouris.get(touristId) ? 0 : cuxTouris.get(touristId);
|
|
|
+ CmBehaviorRecordPo recordPo = cuxTourist.stream().filter(tourist -> tourist.getTouristId().equals(touristId)).collect(Collectors.toList()).get(0);
|
|
|
+ num = null == recordPo.getCount() ? 0 : recordPo.getCount();
|
|
|
// 获取该openId下访问的用户id
|
|
|
List<Integer> userIdAttribute = recordMapper.getUserIdAttribute(format, null, touristId);
|
|
|
boolean userBean = userIdAttribute.contains(0);
|
|
@@ -539,7 +540,7 @@ public class CmBehaviorRecordServiceImpl implements CmBehaviorRecordService {
|
|
|
cmBehaviorRecordPo.setUserId(touristInfoPo.getUserId().toString());
|
|
|
cmBehaviorRecordPo.setTouristId(touristId);
|
|
|
cmBehaviorRecordPo.setAccessDate(format);
|
|
|
- //更具游客信息合并用户浏览记录
|
|
|
+ //根据游客信息合并用户浏览记录
|
|
|
recordMapper.updateBehaviorByTouristId(cmBehaviorRecordPo);
|
|
|
}
|
|
|
}
|