add new permission group
This commit is contained in:
@@ -15,6 +15,7 @@ func (r *Permissions) DefaultPermissions() {
|
|||||||
Permission{Name: "members", Permission: 31},
|
Permission{Name: "members", Permission: 31},
|
||||||
Permission{Name: "events", Permission: 7},
|
Permission{Name: "events", Permission: 7},
|
||||||
Permission{Name: "responsible", Permission: 7},
|
Permission{Name: "responsible", Permission: 7},
|
||||||
|
Permission{Name: "group", Permission: 7},
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -5,13 +5,14 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
type User struct {
|
type User struct {
|
||||||
Id uint `gorm:"primaryKey" json:"id"`
|
Id uint `gorm:"primaryKey" json:"id"`
|
||||||
Name string `gorm:"column:user_name" json:"user"`
|
Name string `gorm:"column:user_name" json:"user"`
|
||||||
Email string `gorm:"column:email" json:"email"`
|
Email string `gorm:"column:email" json:"email"`
|
||||||
Role string `gorm:"column:role" json:"role,omitempty"`
|
Role string `gorm:"column:role" json:"role,omitempty"`
|
||||||
Password string `gorm:"column:password" json:"password"`
|
Password string `gorm:"column:password" json:"password"`
|
||||||
Expiration string `gorm:"column:expiration" json:"expiration,omitempty"`
|
NewPassword string `gorm:"-" json:"newPassword"`
|
||||||
Settings Settings `gorm:"type:json" json:"settings"`
|
Expiration string `gorm:"column:expiration" json:"expiration,omitempty"`
|
||||||
|
Settings Settings `gorm:"type:json" json:"settings"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (u *User) IsValid() bool {
|
func (u *User) IsValid() bool {
|
||||||
|
|||||||
Reference in New Issue
Block a user