|
|
|
@ -21,6 +21,16 @@ func (c *category) All(ctx context.Context) (result []CategoryItem, err error) {
|
|
|
|
|
return
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type ArgsCategoryLists struct {
|
|
|
|
|
Name string
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Lists @Title 分类列表
|
|
|
|
|
func (c *category) Lists(ctx context.Context, args ArgsCategoryLists) (result []CategoryItem, err error) {
|
|
|
|
|
err = client.GetClient(c).Call(ctx, "Lists", args, &result)
|
|
|
|
|
return
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type ArgsCategoryAdd struct {
|
|
|
|
|
Name string // 分类名称
|
|
|
|
|
ParentId uint // 上级id
|
|
|
|
|