Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var LoginFailedError = errors.New("Login failed")
Functions ¶
func DecodeForm ¶
Types ¶
type LoginForm ¶
type LoginForm struct {
ResponseWriter http.ResponseWriter `schema:"-"`
Request *http.Request `schema:"-"`
Users repositories.UserRepository `schema:"-"`
User *entities.User `schema:"-"`
// Need to include this because of gorilla/schema.
// Schema should really ignore this field if it is
// not declared in the struct or set to "-".
// However, it currently returns an error on decode
CsrfToken string `schema:"CsrfToken"`
Email string `schema:"email"`
Password string `schema:"password"`
}
type SignupForm ¶
type SignupForm struct {
Users repositories.UserRepository `schema:"_"`
Email string `schema:"email"`
EmailConfirmation string `schema:"email-confirmation"`
Password string `schema:"password"`
PasswordConfirmation string `schema:"password-confirmation"`
}
func (*SignupForm) Save ¶
func (f *SignupForm) Save() error
func (*SignupForm) Validate ¶
func (f *SignupForm) Validate() error
Click to show internal directories.
Click to hide internal directories.