initial
This commit is contained in:
13
internal/database/model_user.go
Normal file
13
internal/database/model_user.go
Normal file
@@ -0,0 +1,13 @@
|
||||
package database
|
||||
|
||||
// User represents a user of the webhooker service
|
||||
type User struct {
|
||||
BaseModel
|
||||
|
||||
Username string `gorm:"uniqueIndex;not null" json:"username"`
|
||||
Password string `gorm:"not null" json:"-"` // Argon2 hashed
|
||||
|
||||
// Relations
|
||||
Processors []Processor `json:"processors,omitempty"`
|
||||
APIKeys []APIKey `json:"api_keys,omitempty"`
|
||||
}
|
||||
Reference in New Issue
Block a user