add new user and role table in app (in progress)
All checks were successful
Build Quasar SPA and Go Backend for memberApp / build-spa (push) Successful in 2m12s
Build Quasar SPA and Go Backend for memberApp / build-backend (amd64, , linux) (push) Successful in 5m8s
Build Quasar SPA and Go Backend for memberApp / build-backend (amd64, .exe, windows) (push) Successful in 5m8s
Build Quasar SPA and Go Backend for memberApp / build-backend (arm, 6, , linux) (push) Successful in 4m57s
Build Quasar SPA and Go Backend for memberApp / build-backend (arm64, , linux) (push) Successful in 5m7s
All checks were successful
Build Quasar SPA and Go Backend for memberApp / build-spa (push) Successful in 2m12s
Build Quasar SPA and Go Backend for memberApp / build-backend (amd64, , linux) (push) Successful in 5m8s
Build Quasar SPA and Go Backend for memberApp / build-backend (amd64, .exe, windows) (push) Successful in 5m8s
Build Quasar SPA and Go Backend for memberApp / build-backend (arm, 6, , linux) (push) Successful in 4m57s
Build Quasar SPA and Go Backend for memberApp / build-backend (arm64, , linux) (push) Successful in 5m7s
This commit is contained in:
8
backend/models/rights.go
Normal file
8
backend/models/rights.go
Normal file
@@ -0,0 +1,8 @@
|
||||
package models
|
||||
|
||||
type Rights struct {
|
||||
Name string `json:"name,omitempty"`
|
||||
Read bool `json:"read,omitempty"`
|
||||
Write bool `json:"write,omitempty"`
|
||||
Delete bool `json:"delete,omitempty"`
|
||||
}
|
11
backend/models/role.go
Normal file
11
backend/models/role.go
Normal file
@@ -0,0 +1,11 @@
|
||||
package models
|
||||
|
||||
type Role struct {
|
||||
Id int `json:"id"`
|
||||
Role string `json:"role"`
|
||||
Rights []Rights `json:"rights"`
|
||||
}
|
||||
|
||||
func (r *Role) IsValid() bool {
|
||||
return r.Role != ""
|
||||
}
|
@@ -1,7 +1,9 @@
|
||||
package models
|
||||
|
||||
type User struct {
|
||||
Id int `json:"id"`
|
||||
Name string `json:"user"`
|
||||
Email string `json:"email"`
|
||||
Role string `json:"role"`
|
||||
Password string `json:"password,omitempty"`
|
||||
Settings Settings `json:"settings"`
|
||||
|
Reference in New Issue
Block a user