feat: 订阅列表和免费列表
This commit is contained in:
@@ -42,6 +42,25 @@ func (a *CategoryApi) GetCategoryPage(c *gin.Context) {
|
||||
}, c)
|
||||
}
|
||||
|
||||
// GetCategoryTree 获取分类tree
|
||||
// @Tags 分类管理
|
||||
// @Summary 获取分类列表
|
||||
// @Accept application/json
|
||||
// @Produce application/json
|
||||
// @Success 200 {object} response.Response
|
||||
// @Router /radio/category/tree [get]
|
||||
func (a *CategoryApi) GetCategoryTree(c *gin.Context) {
|
||||
list, err := categoryService.GetCategoryTree()
|
||||
if err != nil {
|
||||
global.Logger.Error("获取分类列表失败!", zap.Error(err))
|
||||
response.FailWithMsg(err.Error(), c)
|
||||
return
|
||||
}
|
||||
response.OkWithData(response.ListResult{
|
||||
List: list,
|
||||
}, c)
|
||||
}
|
||||
|
||||
// GetCategoryList 获取分类列表
|
||||
// @Tags 分类管理
|
||||
// @Summary 获取分类列表
|
||||
|
||||
Reference in New Issue
Block a user