|
|
@ -93,11 +93,12 @@ public class CmsController { |
|
|
|
redisUtil.hset(CmsContentServiceImpl.CACHE_CMS_ONLINE, "" + type, dataList); |
|
|
|
redisUtil.hset(CmsContentServiceImpl.CACHE_CMS_ONLINE, "" + type, dataList); |
|
|
|
} |
|
|
|
} |
|
|
|
for (CmsContent data : dataList) { |
|
|
|
for (CmsContent data : dataList) { |
|
|
|
if (CmsTypeEnum.type1.getType().equals(data.getType()) && userSession != null) { |
|
|
|
if (CmsTypeEnum.type2.getType().equals(data.getType()) && userSession != null) { |
|
|
|
// 用户是否阅读
|
|
|
|
// 用户是否阅读,阅读过就不展示
|
|
|
|
data.setExt1(""+cmsContentReadService.isRead(data.getId(), userSession.getUser().getId())); |
|
|
|
data.setExt1(""+(!cmsContentReadService.isRead(data.getId(), userSession.getUser().getId()))); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
data.setExt1("false"); |
|
|
|
// 展示
|
|
|
|
|
|
|
|
data.setExt1("true"); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
return ResponseMsgUtil.success(dataList); |
|
|
|
return ResponseMsgUtil.success(dataList); |
|
|
|