feat: show post participants

This commit is contained in:
Tim
2025-07-10 16:03:02 +08:00
parent 86134a2a7c
commit 2b9b664aa2
5 changed files with 32 additions and 5 deletions

View File

@@ -13,4 +13,7 @@ public interface CommentRepository extends JpaRepository<Comment, Long> {
List<Comment> findByParentOrderByCreatedAtAsc(Comment parent);
List<Comment> findByAuthorOrderByCreatedAtDesc(User author, Pageable pageable);
List<Comment> findByContentContainingIgnoreCase(String keyword);
@org.springframework.data.jpa.repository.Query("SELECT DISTINCT c.author FROM Comment c WHERE c.post = :post")
java.util.List<User> findDistinctAuthorsByPost(@org.springframework.data.repository.query.Param("post") Post post);
}