request

package
v0.0.0-...-22bb83e Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddMenuAuthority

type AddMenuAuthority struct {
	GetAuthorityId
	Menus []model.Menu
}

type AdminLogin

type AdminLogin struct {
	Username  string `p:"username" v:"required|length:1,30#请输入用户名称|您输入用户名称长度非法"`
	Password  string `p:"password" v:"required|length:6,30#请输入密码|密码长度为:min到:max位"`
	Captcha   string `json:"captcha" valid:"required#请输入正确的验证码"`
	CaptchaId string `json:"captchaId" valid:"required|length:20,20#请输入captchaId|您输入captchaId长度非法"`
}

type Authority

type Authority struct {
	AuthorityId   string `r:"authorityId" v:"required|length:1,1000#请输入角色id|角色id长度为:min到:max位"`
	AuthorityName string `r:"authorityName" v:"required|length:1,1000#请输入角色名|角色名长度为:min到:max位"`
}

type BaseAdmin

type BaseAdmin struct {
	Username    string `p:"username" v:"required|length:1,30#请输入用户名称|您输入用户名称长度非法"`
	Password    string `p:"password" v:"required|length:6,30#请输入旧密码|旧密码长度为:min到:max位"`
	NewPassword string `p:"new_password" v:"required|length:6,30#请输入新密码|新密码长度为:min到:max位"`
}

type BaseApi

type BaseApi struct {
	Path        string `p:"path" v:"path@required|length:1,100#请输入api路径|api路径长度为:min到:max位"`
	Method      string `p:"method" v:"method@required|length:1,100#请输入api请求方法|api请求方法长度为:min到:max位"`
	ApiGroup    string `p:"apiGroup" v:"apiGroup@required|length:1,100#请输入api组|api组描述长度为:min到:max位"`
	Description string `p:"description" v:"description@required|length:1,100#请输入api中文描述|api中文描述长度为:min到:max位"`
}

type BaseAuthority

type BaseAuthority struct {
	ParentId      string `p:"parent_id" v:"required|length:1,1000#请输入角色父id|角色父id长度为:min到:max位"`
	AuthorityId   string `p:"authority_id" v:"required|length:1,1000#请输入角色id|角色id长度为:min到:max位"`
	AuthorityName string `p:"authority_name" v:"required|length:1,1000#请输入角色名字|角色名字长度为:min到:max位"`
	DefaultRouter string `p:"defaultRouter"`
}

type BaseBreakpointContinue

type BaseBreakpointContinue struct {
	FileMd5     string `json:"fileMd5" form:"fileMd5"`
	FileName    string `json:"fileName" form:"fileName"`
	FilePath    string `json:"filePath" form:"filePath"`
	ChunkMd5    string `json:"chunkMd5" form:"chunkMd5"`
	ChunkNumber string `json:"chunkNumber" form:"chunkNumber"`
	ChunkTotal  string `json:"chunkTotal" form:"chunkTotal"`

	ChunkNumberInt int
}

type BaseBreakpointContinueChunk

type BaseBreakpointContinueChunk struct {
	FileChunkPath   string `json:"fileChunkPath" form:"fileChunkPath"`
	FileChunkNumber int    `json:"fileChunkNumber" form:"fileChunkNumber"`
}

type BaseDictionary

type BaseDictionary struct {
	Name   string `p:"name" v:"required|length:1,1000#请输入字典中文名|字典中文名长度为:min到:max位"`
	Type   string `p:"type" v:"required|length:1,1000#请输入字典英文名|字典英文名长度为:min到:max位"`
	Desc   string `p:"desc" v:"required|length:1,1000#请输入描述|描述长度为:min到:max位"`
	Status *bool  `p:"status" v:"required|length:1,1000#请输入状态|状态长度为:min到:max位"`
}

type BaseDictionaryDetail

type BaseDictionaryDetail struct {
	Label string `p:"label" v:"label@required|length:1,1000#请输入展示值|展示值长度为:min到:max位"` // 展示值

	Status *bool `p:"status" v:"boolean@required#请输入启用状态"` // 启用状态

	Value        int `p:"value" v:"value@required|length:1,1000#请输入字典值|展示值长度为:min到:max位"`            // 字典值
	Sort         int `p:"sort" v:"label@required|length:1,1000#请输入排序标记|展示值长度为:min到:max位"`            // 排序标记
	DictionaryId int `p:"sysDictionaryID" v:"label@required|length:1,1000#请输入关联标记|展示值长度为:min到:max位"` // 关联标记
}

type BaseFile

type BaseFile struct {
	Url  string `json:"url" gorm:"comment:文件地址"`
	Tag  string `json:"tag" gorm:"comment:文件标签"`
	Key  string `json:"key" gorm:"comment:编号"`
	Name string `json:"name" gorm:"comment:文件名"`
}

type BaseOperationRecord

type BaseOperationRecord struct {
	Ip           string `p:"ip"            v:"required | length:1, 20#请输入ip|ip长度为:min到max"`
	Path         string `p:"path"          v:"required | length:1, 20#请输入请求路由|请求路由长度为:min到max"`
	Agent        string `p:"agent"         v:"required | length:1, 20#请输入代理|代理长度为:min到max"`
	Method       string `p:"method"        v:"required | length:1, 20#请输入请求方法|请求方法长度为:min到max"`
	Request      string `p:"request"       v:"required | length:1, 20#请输入请求Body|请求Body长度为:min到max"`
	Response     string `p:"response"      v:"required | length:1, 20#请输入响应Body|响应Body长度为:min到max"`
	ErrorMessage string `p:"error_message" v:"required | length:1, 20#请输入报错信息|报错信息长度为:min到max"`

	Status  int   `p:"status"        v:"required | length:1, 20#请输入状态|状态长度为:min到max"`
	UserID  int   `p:"user_id"       v:"required | length:1, 20#请输入用户id|用户id长度为:min到max"`
	Latency int64 `p:"latency"       v:"required | length:1, 20#请输入延迟|延迟长度为:min到max"`
}

type BreakpointContinue

type BreakpointContinue struct {
	BaseBreakpointContinue
}

func (*BreakpointContinue) Create

type BreakpointContinueFinish

type BreakpointContinueFinish struct {
	BaseBreakpointContinue
}

type CasbinInfo

type CasbinInfo struct {
	Path   string `json:"path"`
	Method string `json:"method"`
}

type ChangePassword

type ChangePassword struct {
	Uuid        string
	Username    string `p:"username" v:"required|length:1,30#请输入用户名称|您输入用户名称长度非法"`
	Password    string `p:"password" v:"required|length:6,30#请输入旧密码|旧密码长度为:min到:max位"`
	NewPassword string `p:"new_password" v:"required|length:6,30#请输入新密码|新密码长度为:min到:max位"`
}

type CheckFileMd5

type CheckFileMd5 struct {
	Md5 string `json:"md5" form:"md5"`
}

type CopyAuthority

type CopyAuthority struct {
	Authority      model.Authority `json:"authority"`
	OldAuthorityId string          `json:"oldAuthorityId"`
}

type CreateApi

type CreateApi struct {
	BaseApi
}

func (*CreateApi) Create

func (c *CreateApi) Create() *model.Api

type CreateAuthority

type CreateAuthority struct {
	BaseAuthority
}

func (*CreateAuthority) Create

func (c *CreateAuthority) Create() *model.Authority

type CreateCustomer

type CreateCustomer struct {
	CustomerName       string `p:"customerName" v:"required|length:1,1000#请输入客户名|客户名长度为:min到:max位"`
	CustomerPhoneData  string `p:"customerPhoneData" v:"required|length:1,1000#请输入客户电话|客户电话长度为:min到:max位"`
	SysUserId          uint   `p:"sysUserId"`
	SysUserAuthorityId string `p:"sysUserAuthorityId"`
}

type CreateDictionary

type CreateDictionary struct {
	BaseDictionary
}

func (*CreateDictionary) Create

func (c *CreateDictionary) Create() *model.Dictionary

type CreateDictionaryDetail

type CreateDictionaryDetail struct {
	BaseDictionaryDetail
}

func (*CreateDictionaryDetail) Create

type CreateFile

type CreateFile struct {
	BaseFile
}

func (*CreateFile) Create

func (c *CreateFile) Create() *model.File

type CreateFileChunk

type CreateFileChunk struct {
	GetById
	BaseBreakpointContinueChunk
}

func (*CreateFileChunk) Create

type CreateOperationRecord

type CreateOperationRecord struct {
	BaseOperationRecord
}

func (*CreateOperationRecord) Create

type CreateSimpleUpload

type CreateSimpleUpload struct {
	ChunkNumber      string `p:"chunkNumber" v:"required|length:1,1000#请输入当前切片标记|当前切片标记长度为:min到:max位"`
	CurrentChunkPath string `p:"currentChunkPath" v:"required|length:1,1000#请输入切片本地路径|切片本地路径长度为:min到:max位"`
	CurrentChunkSize string `p:"currentChunkSize" v:"required|length:1,1000#请输入当前切片容量|当前切片容量长度为:min到:max位"`
	FilePath         string `p:"filePath" v:"required|length:1,1000#请输入文件本地路径|文件本地路径长度为:min到:max位"`
	Filename         string `p:"filename" v:"required|length:1,1000#请输入文件名|文件名长度为:min到:max位"`
	Identifier       string `p:"identifier" v:"required|length:1,1000#请输入文件标识(md5)|文件标识(md5)长度为:min到:max位"`
	IsDone           bool   `p:"isDone" v:"required|length:1,1000#请输入是否上传完成|是否上传完成长度为:min到:max位"`
	TotalChunks      string `p:"totalChunks" v:"required|length:1,1000#请输入切片总数|切片总数长度为:min到:max位"`
	TotalSize        string `p:"totalSize" v:"required|length:1,1000#请输入总容量|总容量长度为:min到:max位"`
}

type CustomClaims

type CustomClaims struct {
	AdminId          uint    `gconv:"admin_id"`
	AdminUuid        string  `gconv:"admin_uuid"`
	AdminNickname    string  `gconv:"admin_nickname"`
	Exp              float64 `gconv:"exp"`
	OrigIat          float64 `gconv:"orig_iat"`
	AdminAuthorityId string  `gconv:"admin_authority_id"`
}

type DeleteApi

type DeleteApi struct {
	Path   string `p:"path" v:"path@required|length:1,100#请输入api路径|api路径长度为:min到:max位"`
	Method string `p:"method" v:"method@required|length:1,100#请输入api请求方法|api请求方法长度为:min到:max位"`
	GetById
}

type DeleteByIds

type DeleteByIds struct {
	Ids []int `p:"ids" v:"required|length:1,1000#请输入id|id长度为:min到:max位"`
}

@author: [SliverHorn](https://github.com/SliverHorn) @description: Delete by id structure

type ExcelInfo

type ExcelInfo struct {
	FileName string        `json:"fileName"`
	InfoList []system.Menu `json:"infoList"`
}

type FindCustomer

type FindCustomer struct {
	Id                 int    `p:"id" v:"required|length:1,1000#请输入自增ID|自增ID长度为:min到:max位"`
	CustomerName       string `p:"customerName" v:"required|length:1,1000#请输入客户名|客户名长度为:min到:max位"`
	CustomerPhoneData  string `p:"customerPhoneData" v:"required|length:1,1000#请输入客户电话|客户电话长度为:min到:max位"`
	SysUserId          int    `p:"sysUserId" v:"required|length:1,1000#请输入负责员工id|负责员工id长度为:min到:max位"`
	SysUserAuthorityId string `p:"sysUserAuthorityId" v:"required|length:1,1000#请输入负责员工角色|负责员工角色长度为:min到:max位"`
}

type FindFile

type FindFile struct {
	Header *multipart.FileHeader
	BaseBreakpointContinue
}

func (*FindFile) Find

func (f *FindFile) Find() *model.BreakpointContinue

type FirstDictionary

type FirstDictionary struct {
	Id   int    `p:"id" v:"required|length:1,1000#请输入id|id长度为:min到:max位"` // 自增ID
	Type string `p:"type" `
}

FindDictionary 用id查询Dictionary

type GetAuthorityId

type GetAuthorityId struct {
	AuthorityId string `p:"authorityId"`
}

func (*GetAuthorityId) Condition

func (i *GetAuthorityId) Condition() g.Map

type GetById

type GetById struct {
	Id uint `p:"id" v:"required|length:1,1000#请输入id|id长度为:min到:max位"`
}

@author: [SliverHorn](https://github.com/SliverHorn) @description: Get by id structure

func (*GetById) Condition

func (i *GetById) Condition() g.Map

type GetByIds

type GetByIds struct {
	Ids []int `p:"ids" v:"required|length:1,1000#请输入ids|ids长度为:min到:max位"`
}

@author: [SliverHorn](https://github.com/SliverHorn) @description: Get by ids structure

func (*GetByIds) Condition

func (i *GetByIds) Condition() g.Map

type GetByUuid

type GetByUuid struct {
	Uuid string `p:"uuid"`
}

type GetCustomerList

type GetCustomerList struct {
	CustomerName       string `p:"customerName"`
	CustomerPhoneData  string `p:"customerPhoneData"`
	SysUserId          int    `p:"sysUserId"`
	SysUserAuthorityId string `p:"sysUserAuthorityId"`
	PageInfo
}

type GetDictionary

type GetDictionary struct {
	ID   float64 `p:"id" v:"required|length:1,1000#请输入id|id长度为:min到:max位"`
	Type string  `p:"type" v:"required|length:1,1000#请输入字典英文名|字典英文名长度为:min到:max位"`
}

type InitDB

type InitDB struct {
	Host     string `json:"host"`
	Port     string `json:"port"`
	UserName string `json:"userName" binding:"required"`
	Password string `json:"password"`
	DBName   string `json:"dbName" binding:"required"`
}

type MergeFileMd5

type MergeFileMd5 struct {
	Md5      string `json:"md5" form:"md5"`
	Filename string `json:"fileName" form:"fileName"`
}

type PageInfo

type PageInfo struct {
	Page     int `p:"page" v:"required|length:1,1000#请输入页数|页数长度为:min到:max位" json:"page" form:"page"`
	PageSize int `p:"pageSize" v:"required|length:1,1000#请输入每页大小|每页大小为:min到:max位" json:"pageSize" form:"pageSize"`
}

@author: [SliverHorn](https://github.com/SliverHorn) @description: Paging common input parameter structure

func (*PageInfo) Paginate

func (p *PageInfo) Paginate() (limit, offset int)

type Register

type Register struct {
	Avatar      string `p:"headerImg"`
	Username    string `p:"userName"`
	Password    string `p:"passWord"`
	Nickname    string `p:"nickName"`
	AuthorityId string `p:"authorityId"`
}

func (*Register) Create

func (r *Register) Create() *model.Admin

type RemoveChunk

type RemoveChunk struct {
	BaseBreakpointContinue
}

type SearchApi

type SearchApi struct {
	Path        string `p:"path"`
	Description string `p:"description"`
	ApiGroup    string `p:"apiGroup"`
	Method      string `p:"method"`
	PageInfo
}

api分页条件查询及排序结构体

func (*SearchApi) Search

func (s *SearchApi) Search() g.Map

type SearchDictionary

type SearchDictionary struct {
	Status *bool  `p:"status"`
	Name   string `p:"name"`
	Type   string `p:"type"`
	Desc   string `p:"desc"`
	PageInfo
}

func (*SearchDictionary) Search

func (s *SearchDictionary) Search() g.Map

type SearchDictionaryDetail

type SearchDictionaryDetail struct {
	Label        string `p:"label"`           // 展示值
	Status       *bool  `p:"status"`          // 启用状态
	Value        int    `p:"value"`           // 字典值
	Sort         int    `p:"sort"`            // 排序标记
	DictionaryId int    `p:"sysDictionaryID"` // 关联标记
	PageInfo
}

func (*SearchDictionaryDetail) Search

func (s *SearchDictionaryDetail) Search() g.Map

type SearchOperationRecord

type SearchOperationRecord struct {
	Path   string `p:"path"`
	Method string `p:"method"`
	Status int    `p:"status"`
	PageInfo
}

func (*SearchOperationRecord) Search

func (s *SearchOperationRecord) Search() g.Map

type SearchWorkflowProcess

type SearchWorkflowProcess struct {
	model.WorkflowProcess
	PageInfo
}

type SetAuthority

type SetAuthority struct {
	Uuid        string `p:"uuid" v:"required|length:36,36#请输入管理员UUID|管理员UUID长度为:min到:max位"`
	AuthorityId string `p:"authority_id" v:"required|length:1, 100#请输入角色ID|角色ID长度为:min到:max位"`
}

type SetDataAuthority

type SetDataAuthority struct {
	BaseAuthority
	DataAuthorityId []model.Authority `json:"dataAuthorityId" gorm:"many2many:sys_data_authority_id"`
}

type SetMenuAuthority

type SetMenuAuthority struct {
	BaseAuthority
	DataAuthorityId []model.Authority `json:"dataAuthorityId" gorm:"many2many:sys_data_authority_id"`
}

type UpdateAdmin

type UpdateAdmin struct {
	GetById
	Uuid   string
	Avatar string `p:"headerImg" v:"required|length:1, 100#请输入头像链接|头像链接长度为:min到:max位"`
}

type UpdateApi

type UpdateApi struct {
	GetById
	BaseApi
}

func (*UpdateApi) Update

func (u *UpdateApi) Update() *model.Api

type UpdateAuthority

type UpdateAuthority struct {
	BaseAuthority
}

func (*UpdateAuthority) Update

func (u *UpdateAuthority) Update() g.Map

type UpdateCasbin

type UpdateCasbin struct {
	AuthorityId string       `json:"authorityId"`
	CasbinInfos []CasbinInfo `json:"casbinInfos"`
}

type UpdateCustomer

type UpdateCustomer struct {
	Id                 int    `p:"id" v:"required|length:1,1000#请输入自增ID|自增ID长度为:min到:max位"`
	CustomerName       string `p:"customerName" v:"required|length:1,1000#请输入客户名|客户名长度为:min到:max位"`
	CustomerPhoneData  string `p:"customerPhoneData" v:"required|length:1,1000#请输入客户电话|客户电话长度为:min到:max位"`
	SysUserId          int    `p:"sysUserId"`
	SysUserAuthorityId string `p:"sysUserAuthorityId"`
}

type UpdateDictionary

type UpdateDictionary struct {
	GetById
	BaseDictionary
}

func (*UpdateDictionary) Update

func (u *UpdateDictionary) Update() g.Map

type UpdateDictionaryDetail

type UpdateDictionaryDetail struct {
	GetById
	BaseDictionaryDetail
}

func (*UpdateDictionaryDetail) Update

func (u *UpdateDictionaryDetail) Update() g.Map

type UpdateMenu

type UpdateMenu struct {
	model.Menu
}

func (*UpdateMenu) Update

func (u *UpdateMenu) Update() g.Map

type Upload

type Upload struct {
	Filename         string `r:"filename" json:"filename" form:"filename"`
	TotalSize        string `r:"totalSize" json:"totalSize" form:"totalSize"`
	Identifier       string `r:"identifier" json:"identifier" form:"identifier"`
	TotalChunks      string `r:"totalChunks" json:"totalChunks" form:"totalChunks"`
	ChunkNumber      string `r:"chunkNumber" json:"chunkNumber" form:"chunkNumber"`
	CurrentChunkSize string `r:"currentChunkSize" json:"currentChunkSize" form:"currentChunkSize"`
}

func (*Upload) Create

func (u *Upload) Create(path string) model.SimpleUploader

Jump to

Keyboard shortcuts

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