Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
func NewHandler ¶
func NewHandler() *Handler
func (*Handler) CreateRole ¶
func (h *Handler) CreateRole() iris.Handler
Create Role @Tags roles @Summary Create role @Description Create role @Accept json @Produce json @Param request body v1Role.Role true "request" @Success 200 {object} v1Role.Role @Security ApiKeyAuth @Router /roles [post]
func (*Handler) DeleteRole ¶
func (h *Handler) DeleteRole() iris.Handler
Delete Role @Tags roles @Summary Delete role by name @Description Delete role by name @Accept json @Produce json @Param name path string true "角色名称" @Success 200 {object} v1Role.Role @Security ApiKeyAuth @Router /roles/{name} [delete]
func (*Handler) GetRole ¶
func (h *Handler) GetRole() iris.Handler
Get Role @Tags roles @Summary Get role by name @Description Get role by name @Accept json @Produce json @Param name path string true "权限名称" @Success 200 {object} v1Role.Role @Security ApiKeyAuth @Router /roles/{name} [get]
func (*Handler) ListRoles ¶
func (h *Handler) ListRoles() iris.Handler
List Roles @Tags roles @Summary List all roles @Description List all roles @Accept json @Produce json @Success 200 {object} []v1Role.Role @Security ApiKeyAuth @Router /roles [get]
func (*Handler) SearchRoles ¶
func (h *Handler) SearchRoles() iris.Handler
func (*Handler) UpdateRole ¶
func (h *Handler) UpdateRole() iris.Handler
Update Role @Tags roles @Summary Update role by name @Description Update role by name @Accept json @Produce json @Param name path string true "角色名称" @Success 200 {object} v1Role.Role @Security ApiKeyAuth @Router /roles/{name} [put]