fix(home-following): 최근 대화를 팔로우 크리에이터로 제한한다

This commit is contained in:
2026-08-19 12:23:33 +09:00
parent b18e40d4fc
commit b1be87b46f
9 changed files with 570 additions and 20 deletions
@@ -87,6 +87,15 @@ interface ChatRoomRepository : JpaRepository<ChatRoom, Long> {
AND pc.isActive = true
AND r.isActive = true
AND m.isActive = true
AND (
:followedCreatorsOnly = false
OR EXISTS (
SELECT cf.id FROM CreatorFollowing cf
WHERE cf.member.id = :memberId
AND cf.creator.id = pc.character.creatorMember.id
AND cf.isActive = true
)
)
AND (
:cursorAt IS NULL
OR m.createdAt < :cursorAt
@@ -110,6 +119,7 @@ interface ChatRoomRepository : JpaRepository<ChatRoom, Long> {
@Param("cursorAt") cursorAt: LocalDateTime?,
@Param("cursorChatType") cursorChatType: String?,
@Param("cursorRoomId") cursorRoomId: Long?,
@Param("followedCreatorsOnly") followedCreatorsOnly: Boolean,
pageable: Pageable
): List<V2ChatRoomListQueryDto>