refactor(controller/service/repository): 重构分类属性、文章和消息相关功能

重构分类属性相关类名从Category_attribute改为Categoryattribute
优化文章和消息的分页查询功能,新增分页DTO类
移除旧的分页DTO类PageDto,新增ArriclePageDto和MessagePageDto
调整消息统计逻辑,区分文章评论和独立消息
更新安全配置,开放消息新增接口权限
This commit is contained in:
qingfeng1121
2025-12-18 15:19:59 +08:00
parent f27be2130c
commit 15eca0d0b5
20 changed files with 360 additions and 144 deletions

View File

@@ -2,6 +2,7 @@ package com.qf.myafterprojecy.service;
import com.qf.myafterprojecy.exceptopn.ResponseMessage;
import com.qf.myafterprojecy.pojo.Article;
import com.qf.myafterprojecy.pojo.dto.ArriclePageDto;
import com.qf.myafterprojecy.pojo.dto.ArticleDto;
import org.springframework.data.domain.Page;
@@ -25,7 +26,12 @@ public interface IArticleService {
* @return 返回包含文章列表的ResponseMessage对象
*/
ResponseMessage<List<Article>> getArticlesByStatus(Integer status);
/**
* 获取文章数量
* @param status 文章状态0未发表 1已发表 2已删除
* @return 返回文章数量
*/
ResponseMessage<Integer> getArticleCount(Integer status);
/**
* 创建新文章
* 仅限AUTHOR角色用户访问
@@ -98,5 +104,5 @@ public interface IArticleService {
* @param size 每页大小
* @return 返回包含分页文章列表的ResponseMessage对象
*/
ResponseMessage<Page<Article>> getArticlesByStatusWithPagination(Integer status, Integer page, Integer size);
ResponseMessage<Page<Article>> getArticlesByStatusWithPagination(ArriclePageDto arriclePageDto);
}