mirror of
https://github.com/nagisa77/OpenIsle.git
synced 2026-06-06 05:46:05 +00:00
feat: add user leveling and experience system
This commit is contained in:
@@ -87,6 +87,9 @@ public interface PostRepository extends JpaRepository<Post, Long> {
|
||||
@Query("SELECT SUM(p.views) FROM Post p WHERE p.author.username = :username AND p.status = com.openisle.model.PostStatus.PUBLISHED")
|
||||
Long sumViews(@Param("username") String username);
|
||||
|
||||
@Query("SELECT COUNT(p) FROM Post p WHERE p.author.username = :username AND p.createdAt >= :start")
|
||||
long countByAuthorAfter(@Param("username") String username, @Param("start") java.time.LocalDateTime start);
|
||||
|
||||
long countByCategory_Id(Long categoryId);
|
||||
|
||||
long countDistinctByTags_Id(Long tagId);
|
||||
|
||||
Reference in New Issue
Block a user