Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CompanyRequest ¶
type CompanyRequest struct {
Name string `json:"name" binding:"required,min=1"`
}
type EntryRequest ¶
type PaginationRequest ¶
type PaginationRequest struct { Offset int32 `form:"offset" binding:"min=0"` Limit int32 `form:"limit,default=10" binding:"min=1,max=100"` }
Pagination contains pagination request
type RequestWithID ¶
type RequestWithID struct {
ID int64 `uri:"id" binding:"required,min=1,max=9223372036854775807"`
}
RequestWithID is used for requests searching for a resource by ID
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server stores information about a server.
type UserRequest ¶
type UserRequest struct { // Required information Username string `json:"username" binding:"required,alphanum"` Name string `json:"name" binding:"required,min=1"` Surname string `json:"surname" binding:"required,min=1"` Email string `json:"email" binding:"required,email"` BirthDate time.Time `json:"birth_date" binding:"required,lt"` Gender string `json:"gender" binding:"omitempty,gender"` Language string `json:"language" binding:"omitempty,language"` Timezone string `json:"timezone" binding:"omitempty"` // Optional user information Country *string `json:"country,omitempty" binding:"omitempty,len=2,ascii"` // Foreign keys CompanyID *int64 `json:"company_id"` ManagerID *int64 `json:"manager_id"` TeamID *int64 `json:"team_id"` }
Click to show internal directories.
Click to hide internal directories.