user

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 23, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Register

func Register(r *gin.Engine) error

Types

type ApiUser

type ApiUser struct {
	// contains filtered or unexported fields
}

func NewUserApi

func NewUserApi(c framework.Container) *ApiUser

func (*ApiUser) GetUserInfo

func (api *ApiUser) GetUserInfo(c *gin.Context)

GetUserInfo godoc @Summary 获取用户详情的接口 @Security ApiKeyAuth @Description 根据token获取id @Produce json @Tags User @Success 200 {object} base.Response @Router /user/info [get]

func (*ApiUser) Login

func (api *ApiUser) Login(c *gin.Context)

Login godoc @Summary 用户登录接口 @Security ApiKeyAuth @Description 用户登录接口 @accept application/json @Produce application/json @Param data body sys.LoginRequest true "用户名,密码,账户类型" @Tags User @Success 200 {object} base.Response @Router /user/login [post]

func (*ApiUser) Logout

func (api *ApiUser) Logout(c *gin.Context)

Logout godoc @Summary 用户退出接口 @Security ApiKeyAuth @Description 用户退出接口 @Produce json @Tags User @Success 200 {object} base.Response @Router /user/logout [post]

func (*ApiUser) Register

func (api *ApiUser) Register(c *gin.Context)

Register godoc @Summary 用户注册接口 @Security ApiKeyAuth @Description 用户注册接口 @Produce json @Tags User @Success 200 {object} base.Response @Router /user/register [post]

func (*ApiUser) UserRelativeGroup

func (api *ApiUser) UserRelativeGroup(c *gin.Context)

UserRelativeGroup godoc @Summary 获得用户分组资源接口 @Security ApiKeyAuth @Description 获得用户分组资源接口 @accept application/json @Produce application/json @Param id path int true "用户id" @Param domain query string false "域" @Tags User @Success 200 {object} base.Response @Router /user/relative/group/{id} [get]

func (*ApiUser) UserRelativeGroupAdd

func (api *ApiUser) UserRelativeGroupAdd(c *gin.Context)

UserRelativeGroupAdd godoc @Summary 新增用户分组接口 @Security ApiKeyAuth @Description 新增用户分组接口 @accept application/json @Produce application/json @Param data body sys.RelativeUserRequest true "关联参数" @Tags User @Success 200 {object} base.Response @Router /user/relative/group/add [post]

func (*ApiUser) UserRelativeGroupDelete

func (api *ApiUser) UserRelativeGroupDelete(c *gin.Context)

UserRelativeGroupDelete godoc @Summary 删除用户分组接口 @Security ApiKeyAuth @Description 删除用户分组接口 @accept application/json @Produce application/json @Param data body sys.RelativeUserRequest true "关联参数" @Tags User @Success 200 {object} base.Response @Router /user/relative/group/delete [delete]

func (*ApiUser) UserRelativeMenu

func (api *ApiUser) UserRelativeMenu(c *gin.Context)

UserRelativeMenu godoc @Summary 获得用户菜单接口 @Security ApiKeyAuth @Description 获得用户菜单接口 @accept application/json @Produce application/json @Param id path int true "用户id" @Param domain query string false "域" @Tags User @Success 200 {object} base.Response @Router /user/relative/menu/{id} [get]

func (*ApiUser) UserRelativeRole

func (api *ApiUser) UserRelativeRole(c *gin.Context)

UserRelativeRole godoc @Summary 获得用户角色权限接口 @Security ApiKeyAuth @Description 获得用户角色权限接口 @accept application/json @Produce application/json @Param id path int true "用户id" @Param domain query string false "域" @Tags User @Success 200 {object} base.Response @Router /user/relative/role/{id} [get]

func (*ApiUser) UserRelativeRoleAdd

func (api *ApiUser) UserRelativeRoleAdd(c *gin.Context)

UserRelativeRoleAdd godoc @Summary 用户关联角色接口 @Security ApiKeyAuth @Description 用户关联角色接口 @accept application/json @Produce application/json @Param data body sys.RelativeUserRequest true "关联参数" @Tags User @Success 200 {object} base.Response @Router /user/relative/role/add [post]

func (*ApiUser) UserRelativeRoleDelete

func (api *ApiUser) UserRelativeRoleDelete(c *gin.Context)

UserRelativeRoleDelete godoc @Summary 删除用户角色接口 @Security ApiKeyAuth @Description 删除用户角色接口 @accept application/json @Produce application/json @Param data body sys.RelativeUserRequest true "关联参数" @Tags User @Success 200 {object} base.Response @Router /user/relative/role/delete [delete]

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL