model

package
v0.0.0-...-dacb89a Latest Latest
Warning

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

Go to latest
Published: Nov 27, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type User

type User struct {
	Id                int    `json:"id"`
	Phone             string `json:"phone"`
	Password          string `json:"password,omitempty"`
	EncryptedPassword string `json:"-"`
}

func TestUser

func TestUser(t *testing.T) *User

func (*User) BeforeCreate

func (u *User) BeforeCreate() error

func (*User) ComparePassword

func (u *User) ComparePassword(password string) bool

func (*User) Sanitize

func (u *User) Sanitize()

func (*User) Validate

func (u *User) Validate() error

Jump to

Keyboard shortcuts

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