Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ public interface CompleteRepository extends JpaRepository<Complete, Integer> {
@Query("select c from Complete c where c.todo.goal.user.userId in :userIds order by c.createdAt desc")
Slice<Complete> findByFollowees(@Param("userIds") List<Integer> userIds, Pageable pageable);

@Query("select c from Complete c where c.todo.goal.user.userId in :userIds and c.completeId > :completeId order by c.createdAt desc")
@Query("select c from Complete c where c.todo.goal.user.userId in :userIds and c.completeId < :completeId order by c.createdAt desc")
Slice<Complete> findByFolloweesAfterCompleteId(@Param("userIds")List<Integer> followeeIds, @Param("completeId") Integer completeId, Pageable pageable);
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
@Builder
public record ReadFollowResponse(
int completeId,
int userId,
String completePic,
String completeContent,
String profilePic,
Expand All @@ -22,6 +23,7 @@ public record ReadFollowResponse(
public static ReadFollowResponse from(Complete complete, Boolean likeStatus) {
return ReadFollowResponse.builder()
.completeId(complete.getCompleteId())
.userId(complete.getTodo().getGoal().getUser().getUserId())
.completePic(complete.getCompletePic())
.completeContent(complete.getNote())
.profilePic(complete.getTodo().getGoal().getUser().getProfilePic())
Expand Down
Loading