Documentation ¶
Index ¶
Constants ¶
View Source
const (
CookieCertificateKey = "WarehouseSessionID"
)
Variables ¶
View Source
var ResponseMessages map[ResponseCode]string = map[ResponseCode]string{ RespSuccess: "success", RespSystemFailed: "system failed", RespUserMismatch: "login failed, id mismatch", RespPasswordMismatch: "login failed, password mismatch", RespUserExpired: "login failed, user expired", RespUserLocked: "login failed, user locked", RespPasswordExpired: "login failed, password expired", }
Functions ¶
func NewHandlerResponse ¶
func NewHandlerResponse(status ResponseCode, data string) gin.H
Types ¶
type HandlerResponse ¶
func NewLoginResponse ¶
func NewLoginResponse(status ResponseCode, session sessions.Session, cert model.Certificate, data string) HandlerResponse
type LoginParam ¶
type LoginResponse ¶
type LoginResponse struct {
// contains filtered or unexported fields
}
func (*LoginResponse) Response ¶
func (r *LoginResponse) Response() gin.H
type ResponseCode ¶
type ResponseCode int
const ( RespSuccess ResponseCode = iota RespSystemFailed RespUserMismatch RespPasswordMismatch RespUserExpired RespUserLocked RespPasswordExpired )
Click to show internal directories.
Click to hide internal directories.