Skip to content

Commit

Permalink
fix: 북마크기능에 모든 모임이 조회되도록 변경 (#207)
Browse files Browse the repository at this point in the history
  • Loading branch information
ddingmin authored Feb 12, 2024
1 parent 9c6f2c9 commit c4fc748
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public MeetingResponse getMeetingById(@PathVariable("meetingId") Long meetingId)
@ResponseStatus(HttpStatus.OK)
public PageDto<MeetingsResponse> getMeetingsByCondition(
Pageable pageable,
@RequestParam(value = "isOpen") boolean isOpen,
@RequestParam(value = "isOpen", required = false) Boolean isOpen,
@RequestParam(value = "topic", required = false) Topic topic,
@RequestParam(value = "meetingAreaStreet", required = false) String meetingAreaStreet,
@RequestParam(value = "participantUserId", required = false) Long participantUserId,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public void deleteMeeting(Long meetingId, Long userId) {

@Transactional(readOnly = true)
public PageDto<MeetingsResponse> getMeetingsBySpecification(Pageable pageable, Topic topic, String meetingAreaStreet,
Long participantUserId, String searchWord, Boolean isBookmarked, boolean isOpen, Long userId) {
Long participantUserId, String searchWord, Boolean isBookmarked, Boolean isOpen, Long userId) {

Specification<Meeting> spec = MeetingSpecification.withIsOpen(isOpen);

Expand All @@ -110,7 +110,7 @@ public PageDto<MeetingsResponse> getMeetingsBySpecification(Pageable pageable, T
.or(MeetingSpecification.withSearchWordInIntroduction(searchWord))
.and(MeetingSpecification.withIsOpen(isOpen));
} else if (Boolean.TRUE.equals(isBookmarked)) {
spec = spec.and(MeetingSpecification.withBookmarkedUserId(userId));
spec = MeetingSpecification.withBookmarkedUserId(userId);
}

var meetings = meetingRepository.findAll(spec, pageable);
Expand Down

0 comments on commit c4fc748

Please sign in to comment.