Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Permission ¶
type Product ¶
type Role ¶
type Role struct { Id uint `json:"id"` Name string `json:"name"` Permissions []Permission `json:"permissions" gorm:"many2many:role_permissions"` }
type User ¶
type User struct { Id uint `json:"id"` FirstName string `json:"first_name"` LastName string `json:"last_name"` Email string `gorm:"unique" json:"email"` Password []byte `json:"-"` RoleId uint `json:"role_id"` Role Role `json:"role" gorm:"foreignKey:RoleId"` }
func (*User) ComparePassword ¶
func (*User) SetPassword ¶
Source Files ¶
Click to show internal directories.
Click to hide internal directories.