Add cmd for generating code from the new models
Some checks are pending
/ test (push) Waiting to run
Some checks are pending
/ test (push) Waiting to run
This commit is contained in:
parent
67b507f4bd
commit
bf5180559f
9 changed files with 401 additions and 132 deletions
22
storage-new/models/0allTypes.go
Normal file
22
storage-new/models/0allTypes.go
Normal file
|
@ -0,0 +1,22 @@
|
|||
package models
|
||||
|
||||
var AllTypes = []any{
|
||||
&Emote{},
|
||||
&MediaMetadata{},
|
||||
&Note{},
|
||||
&NoteToAttachment{},
|
||||
&NoteToEmote{},
|
||||
&NoteToPing{},
|
||||
&NoteTag{},
|
||||
&Reaction{},
|
||||
&RemoteServer{},
|
||||
&Role{},
|
||||
&User{},
|
||||
&UserAuthMethod{},
|
||||
&UserToBeing{},
|
||||
&UserInfoField{},
|
||||
&UserToUserRelation{},
|
||||
&UserRemoteLinks{},
|
||||
&UserToTag{},
|
||||
&UserToRole{},
|
||||
}
|
|
@ -41,7 +41,7 @@ type Role struct {
|
|||
gorm.Model
|
||||
|
||||
// Name of the role
|
||||
Name string `gorm:"primaryKey;unique"`
|
||||
Name string `gorm:"unique"`
|
||||
|
||||
// Priority of the role
|
||||
// Lower priority gets applied first and thus overwritten by higher priority ones
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue