|
|
@ -16,17 +16,13 @@ type CategoryItem struct {
|
|
|
|
Children []CategoryItem `json:"children"`
|
|
|
|
Children []CategoryItem `json:"children"`
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
type ArgsCategoryAll struct {
|
|
|
|
|
|
|
|
Hidden uint // 隐藏状态 1=隐藏 2=显示
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// All @Title 获取分类
|
|
|
|
// All @Title 获取分类
|
|
|
|
func (c *category) All(ctx context.Context, args ArgsCategoryAll) (result []CategoryItem, err error) {
|
|
|
|
func (c *category) All(ctx context.Context, args int) (result []CategoryItem, err error) {
|
|
|
|
xClient, err := client.GetClient(c)
|
|
|
|
xClient, err := client.GetClient(c)
|
|
|
|
if err != nil {
|
|
|
|
if err != nil {
|
|
|
|
return
|
|
|
|
return
|
|
|
|
}
|
|
|
|
}
|
|
|
|
err = xClient.Call(ctx, "All", args, &result)
|
|
|
|
err = xClient.Call(ctx, "All", 0, &result)
|
|
|
|
return
|
|
|
|
return
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|