⬆️ Upgrade Passport
This commit is contained in:
@ -10,7 +10,7 @@ const (
|
||||
type Channel struct {
|
||||
BaseModel
|
||||
|
||||
Alias string `json:"alias" gorm:"uniqueIndex"`
|
||||
Alias string `json:"alias"`
|
||||
Name string `json:"name"`
|
||||
Description string `json:"description"`
|
||||
Members []ChannelMember `json:"members"`
|
||||
@ -19,7 +19,7 @@ type Channel struct {
|
||||
Type ChannelType `json:"type"`
|
||||
Account Account `json:"account"`
|
||||
AccountID uint `json:"account_id"`
|
||||
RealmID uint `json:"realm_id"`
|
||||
RealmID *uint `json:"realm_id"`
|
||||
}
|
||||
|
||||
type NotifyLevel = int8
|
||||
|
15
pkg/models/realms.go
Normal file
15
pkg/models/realms.go
Normal file
@ -0,0 +1,15 @@
|
||||
package models
|
||||
|
||||
// Realm profiles basically fetched from Hydrogen.Passport
|
||||
// But cache at here for better usage and database relations
|
||||
type Realm struct {
|
||||
BaseModel
|
||||
|
||||
Alias string `json:"alias"`
|
||||
Name string `json:"name"`
|
||||
Description string `json:"description"`
|
||||
Channels []Channel `json:"channels"`
|
||||
IsPublic bool `json:"is_public"`
|
||||
IsCommunity bool `json:"is_community"`
|
||||
ExternalID uint `json:"external_id"`
|
||||
}
|
Reference in New Issue
Block a user