派生自 projectDept/qhighschool

EricsHu
2022-12-05 068fc7f2e81178e55fa191a13709af64b1a163f6
src/main/java/com/qxueyou/scc/admin/notice/dao/NoticeDAO.java
@@ -47,18 +47,18 @@
    }
    /**
     * 记录已读的学员
     * 记录已读的学员
     *
     * @param noticeId
     * @param userId
     */
    public void addReadCount(String noticeId, String userId) {
        cache.lstRemove("noticeReadCount" + noticeId, userId);//删除用户之前查看的记录,避免重复记录;
        cache.lstRemove("noticeReadCount" + noticeId, userId);//删除用户之前查看的记录,避免重复记录;
        cache.lstRightPush("noticeReadCount" + noticeId, userId);
    }
    /**
     * 获取已读的学员人数
     * 获取已读的学员人数
     */
    public int getReadCount(String noticeId) {
        List<Object> lstAll = cache.lstAll("noticeReadCount" + noticeId);
@@ -66,7 +66,7 @@
    }
    /**
     * 删除cache的key
     * 删除cache的key
     */
    public void deleteNoticeForCache(String noticeId) {
        cache.delete("noticeReadCount" + noticeId);