[#457][FIX] 책 상세 독서모임 필터에 무관한 모임이 뜨던 문제 수정 - #458
Merged
Conversation
getGatheringsForBook 의 필터 목록을 personal_book.gathering_id 기반에서 meeting 기반으로 변경. 그 책으로 약속(meeting.book_id)이 잡혔고 사용자가 그 약속의 멤버(meeting_member)인 모임만 반환한다. - 기존(32edb81): personal_book_id 단일 행만 조회 → 개인 책장 사본(gathering null) 진입 시 빈 목록, 같은 책이 여러 모임에서 읽혀도 1개만 노출. - meeting 기반은 모임 책장 도출 방식(약속에 달린 책)과 일치하며, 타임라인(m.book_id) 이 보여주는 모임 집합과 동일. 서비스는 personalBookId 를 실제 bookId 로 변환해 전달. 회귀 테스트로 @DataJpaTest(PersonalBookRepositoryGatheringFilterTest) 추가. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR 요약
이슈 번호
Closes #457
주요 변경 사항
PersonalBookRepository.findActiveGatheringsWithMeetingsByUserAndBook:personal_bookJOIN →meeting기반으로 교체.m.book_id = :bookId이고 사용자가meeting_member인 모임의 gathering 만 DISTINCT 반환. 파라미터도personalBookId→bookId.PersonalReadingRecordService.getGatheringsForBook:personalBook.getBook().getId()로 실제 bookId 를 해석해 전달.PersonalReadingRecordServiceTest: 서비스가 personalBookId(10L) 가 아닌 실제 bookId(100L) 로 조회하는지 검증(회귀 방지).PersonalBookRepositoryGatheringFilterTest(신규, @DataJpaTest): 무관한 책 모임 제외 / 미참여 모임 제외 / 중복 제거 검증.참고 사항
./gradlew test --tests "*PersonalBookRepositoryGatheringFilterTest" --tests "*PersonalReadingRecordServiceTest"통과.🤖 Generated with Claude Code