增加多租户隔离初版
This commit is contained in:
@ -14,6 +14,7 @@ const Token = "X-Auth-Token"
|
||||
func SetupRoutes() *echo.Echo {
|
||||
|
||||
e := echo.New()
|
||||
e.HideBanner = true
|
||||
|
||||
e.File("/", "web/build/index.html")
|
||||
e.File("/logo.svg", "web/build/logo.svg")
|
||||
|
@ -22,6 +22,7 @@ type Asset struct {
|
||||
Active bool `json:"active"`
|
||||
Created utils.JsonTime `json:"created"`
|
||||
Tags string `json:"tags"`
|
||||
Creator string `json:"creator"`
|
||||
}
|
||||
|
||||
func (r *Asset) TableName() string {
|
||||
|
@ -10,6 +10,7 @@ type Command struct {
|
||||
Name string `json:"name"`
|
||||
Content string `json:"content"`
|
||||
Created utils.JsonTime `json:"created"`
|
||||
Creator string `json:"creator"`
|
||||
}
|
||||
|
||||
func (r *Command) TableName() string {
|
||||
|
@ -20,6 +20,7 @@ type Credential struct {
|
||||
PrivateKey string `json:"privateKey"`
|
||||
Passphrase string `json:"passphrase"`
|
||||
Created utils.JsonTime `json:"created"`
|
||||
Creator string `json:"creator"`
|
||||
}
|
||||
|
||||
func (r *Credential) TableName() string {
|
||||
|
@ -15,6 +15,7 @@ type User struct {
|
||||
Online bool `json:"online"`
|
||||
Enabled bool `json:"enabled"`
|
||||
Created utils.JsonTime `json:"created"`
|
||||
Role string `json:"role"`
|
||||
}
|
||||
|
||||
func (r *User) TableName() string {
|
||||
|
Reference in New Issue
Block a user