serv\web-侧边栏 标签统一
This commit is contained in:
@@ -1,105 +0,0 @@
|
||||
package org.xyzh.api.news.category;
|
||||
|
||||
import org.xyzh.common.core.domain.ResultDomain;
|
||||
import org.xyzh.common.dto.resource.TbResourceCategory;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @description 资源分类服务接口
|
||||
* @filename ResourceCategoryService.java
|
||||
* @author yslg
|
||||
* @copyright xyzh
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
public interface ResourceCategoryService {
|
||||
|
||||
/**
|
||||
* @description 获取所有分类列表
|
||||
* @return ResultDomain<TbResourceCategory> 分类列表
|
||||
* @author yslg
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
ResultDomain<TbResourceCategory> getAllCategories();
|
||||
|
||||
/**
|
||||
* @description 获取分类树形结构
|
||||
* @return ResultDomain<TbResourceCategory> 分类树
|
||||
* @author yslg
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
ResultDomain<TbResourceCategory> getCategoryTree();
|
||||
|
||||
/**
|
||||
* @description 根据ID获取分类详情
|
||||
* @param categoryID 分类ID
|
||||
* @return ResultDomain<TbResourceCategory> 分类详情
|
||||
* @author yslg
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
ResultDomain<TbResourceCategory> getCategoryById(String categoryID);
|
||||
|
||||
/**
|
||||
* @description 根据父ID获取子分类
|
||||
* @param parentID 父分类ID
|
||||
* @return ResultDomain<TbResourceCategory> 子分类列表
|
||||
* @author yslg
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
ResultDomain<TbResourceCategory> getCategoriesByParent(String parentID);
|
||||
|
||||
/**
|
||||
* @description 创建分类
|
||||
* @param category 分类信息
|
||||
* @return ResultDomain<TbResourceCategory> 创建结果
|
||||
* @author yslg
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
ResultDomain<TbResourceCategory> createCategory(TbResourceCategory category);
|
||||
|
||||
/**
|
||||
* @description 更新分类
|
||||
* @param category 分类信息
|
||||
* @return ResultDomain<TbResourceCategory> 更新结果
|
||||
* @author yslg
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
ResultDomain<TbResourceCategory> updateCategory(TbResourceCategory category);
|
||||
|
||||
/**
|
||||
* @description 删除分类
|
||||
* @param categoryID 分类ID
|
||||
* @return ResultDomain<Boolean> 删除结果
|
||||
* @author yslg
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
ResultDomain<Boolean> deleteCategory(String categoryID);
|
||||
|
||||
/**
|
||||
* @description 更新分类排序
|
||||
* @param categoryID 分类ID
|
||||
* @param orderNum 排序号
|
||||
* @return ResultDomain<TbResourceCategory> 更新结果
|
||||
* @author yslg
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
ResultDomain<TbResourceCategory> updateCategoryOrder(String categoryID, Integer orderNum);
|
||||
|
||||
/**
|
||||
* @description 检查分类是否有子分类
|
||||
* @param categoryID 分类ID
|
||||
* @return ResultDomain<Boolean> 是否有子分类
|
||||
* @author yslg
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
ResultDomain<Boolean> hasChildCategories(String categoryID);
|
||||
|
||||
/**
|
||||
* @description 检查分类下是否有资源
|
||||
* @param categoryID 分类ID
|
||||
* @return ResultDomain<Boolean> 是否有资源
|
||||
* @author yslg
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
ResultDomain<Boolean> hasResources(String categoryID);
|
||||
}
|
||||
@@ -167,11 +167,11 @@ public interface ResourceService {
|
||||
/**
|
||||
* @description 搜索资源
|
||||
* @param keyword 关键词
|
||||
* @param categoryID 分类ID(可选)
|
||||
* @param tagID 分类ID(可选)
|
||||
* @param status 状态(可选)
|
||||
* @return ResultDomain<TbResource> 搜索结果
|
||||
* @author yslg
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
ResultDomain<TbResource> searchResources(String keyword, String categoryID, Integer status);
|
||||
ResultDomain<TbResource> searchResources(String keyword, String tagID, Integer status);
|
||||
}
|
||||
|
||||
@@ -68,6 +68,15 @@ public interface TagService {
|
||||
*/
|
||||
ResultDomain<TbTag> searchTagsByName(String name);
|
||||
|
||||
/**
|
||||
* @description 根据标签类型获取标签列表
|
||||
* @param tagType 标签类型(1-文章分类标签 2-课程分类标签 3-学习任务分类标签)
|
||||
* @return ResultDomain<TbTag> 标签列表
|
||||
* @author yslg
|
||||
* @since 2025-10-27
|
||||
*/
|
||||
ResultDomain<TbTag> getTagsByType(Integer tagType);
|
||||
|
||||
// ----------------资源标签关联相关--------------------------------
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user