|
@@ -45,6 +45,10 @@ public class StatisticsServiceImpl implements IStatisticsService {
|
|
|
private VisitorManageMapper visitorManageMapper;
|
|
|
@Autowired
|
|
|
private RedisCache redisCache;
|
|
|
+ @Autowired
|
|
|
+ private HouseInfoMapper houseInfoMapper;
|
|
|
+ @Autowired
|
|
|
+ private ProprietorCarMapper proprietorCarMapper;
|
|
|
|
|
|
|
|
|
@Override
|
|
@@ -185,7 +189,7 @@ public class StatisticsServiceImpl implements IStatisticsService {
|
|
|
*/
|
|
|
@Override
|
|
|
public AjaxResult yeZhuTips(ResidentInfo residentInfo) {
|
|
|
- Map<String, Object> map = new HashMap<>(5);
|
|
|
+ Map<String, Object> map = new HashMap<>(7);
|
|
|
Long userId = residentInfo.getUserId();
|
|
|
//物业报修未完成的数量 投诉建议未回复的数量 社区资讯未读数量
|
|
|
String userRepairKey = PROPERTY_REPAIR_NO + userId;
|
|
@@ -225,17 +229,17 @@ public class StatisticsServiceImpl implements IStatisticsService {
|
|
|
if (type.equals(TWO) || type.equals(FIV)) {
|
|
|
likeCount = likeCount + 1;
|
|
|
}
|
|
|
- if (likeCount==99){
|
|
|
+ if (likeCount == 99) {
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
for (String hKey : commentInteractionUserMap.keySet()) {
|
|
|
//找到所有评论的数量targetType = 2|5
|
|
|
String type = hKey.split(":")[0];
|
|
|
- if (type.equals(ONE) || type.equals(FOR)){
|
|
|
+ if (type.equals(ONE) || type.equals(FOR)) {
|
|
|
contentCount = contentCount + 1;
|
|
|
}
|
|
|
- if (contentCount==99){
|
|
|
+ if (contentCount == 99) {
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
@@ -243,6 +247,16 @@ public class StatisticsServiceImpl implements IStatisticsService {
|
|
|
}
|
|
|
map.put("likeCount", likeCount);
|
|
|
map.put("contentCount", contentCount);
|
|
|
+
|
|
|
+ //我的房屋
|
|
|
+ int houseCount = 0;
|
|
|
+ List<ResidentInfo> residentInfos = houseInfoMapper.selectHouseInfoListAndResidentInfo(residentInfo);
|
|
|
+ if (residentInfos != null && residentInfos.size() > 0) {
|
|
|
+ houseCount = residentInfos.size();
|
|
|
+ }
|
|
|
+ map.put("houseCount", houseCount);
|
|
|
+ //我的车辆
|
|
|
+ map.put("carCount", proprietorCarMapper.selectProprietorCarCount(residentInfo.getResidentPhone()));
|
|
|
return AjaxResult.success(map);
|
|
|
}
|
|
|
|