Implement profile page and related backend APIs

This commit is contained in:
Tim
2025-07-09 13:40:54 +08:00
parent d9322307fe
commit 37d1f2ab70
8 changed files with 198 additions and 106 deletions

View File

@@ -69,4 +69,12 @@ public class ReactionService {
.orElseThrow(() -> new IllegalArgumentException("Comment not found"));
return reactionRepository.findByComment(comment);
}
public java.util.List<Long> topPostIds(String username, int limit) {
return reactionRepository.findTopPostIds(username, org.springframework.data.domain.PageRequest.of(0, limit));
}
public java.util.List<Long> topCommentIds(String username, int limit) {
return reactionRepository.findTopCommentIds(username, org.springframework.data.domain.PageRequest.of(0, limit));
}
}