Documentation ¶
Index ¶
- func FxModule() fx.Option
- type CharacterArt
- type Group
- type GroupFilter
- type GroupType
- type PictureArt
- type Service
- func (s *Service) GetCharacterArt(server ark.Server, id string) (*CharacterArt, error)
- func (s *Service) GetCharacterArts(server ark.Server) ([]*CharacterArt, error)
- func (s *Service) GetPictureArt(server ark.Server, id string) (*PictureArt, error)
- func (s *Service) GetPictureArts(server ark.Server) ([]*PictureArt, error)
- func (s *Service) GetStories(server ark.Server) ([]*Story, error)
- func (s *Service) GetStory(server ark.Server, id string) (*Story, error)
- func (s *Service) GetStoryGroup(server ark.Server, id string) (*Group, error)
- func (s *Service) GetStoryGroups(server ark.Server, filter GroupFilter) ([]*Group, error)
- func (s *Service) PopulateFrom(rawTree *arkparser.StoryTree, server ark.Server) error
- type Story
- type Tag
- type Tree
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type CharacterArt ¶
type CharacterArt struct { Server ark.Server `json:"server" gorm:"primaryKey;type:game_server"` ID string `json:"id" gorm:"primaryKey;check:id=lower(id)"` StoryID string `json:"storyID" gorm:"primaryKey"` Category string `json:"category" gorm:""` Names pq.StringArray `json:"names" gorm:"type:text[]"` SortID *uint64 `json:"-" gorm:"unique;autoIncrement"` }
type Group ¶
type Group struct { Server ark.Server `json:"server" gorm:"primaryKey;type:game_server"` ID string `json:"id" gorm:"primaryKey;check:id=lower(id)"` Name string `json:"name" gorm:""` Type GroupType `json:"type" gorm:"type:story_group_type"` Stories []Story `json:"stories" gorm:"foreignKey:Server,GroupID;reference:Server,ID;constraint:OnDelete:CASCADE"` SortID *uint64 `json:"-" gorm:"unique;autoIncrement"` }
type GroupFilter ¶
type GroupFilter struct {
Type string
}
type PictureArt ¶
type PictureArt struct { Server ark.Server `json:"server" gorm:"primaryKey;type:game_server"` ID string `json:"id" gorm:"primaryKey;check:id=lower(id)"` StoryID string `json:"storyID" gorm:"primaryKey"` Category string `json:"category" gorm:""` Title string `json:"title" gorm:""` Subtitle string `json:"subtitle" gorm:""` SortID *uint64 `json:"-" gorm:"unique;autoIncrement"` }
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func (*Service) GetCharacterArt ¶
func (*Service) GetCharacterArts ¶
func (s *Service) GetCharacterArts(server ark.Server) ([]*CharacterArt, error)
func (*Service) GetPictureArt ¶
func (*Service) GetPictureArts ¶
func (s *Service) GetPictureArts(server ark.Server) ([]*PictureArt, error)
func (*Service) GetStoryGroup ¶
func (*Service) GetStoryGroups ¶
type Story ¶
type Story struct { Server ark.Server `json:"server" gorm:"primaryKey;type:game_server"` ID string `json:"id" gorm:"primaryKey;check:id=lower(id)"` Tag Tag `json:"tag" gorm:"type:story_tag"` TagText string `json:"tagText" gorm:""` Code string `json:"code" gorm:""` Name string `json:"name" gorm:""` Info string `json:"info" gorm:""` GroupID string `json:"groupID" gorm:""` SortID *uint64 `json:"-" gorm:"unique;autoIncrement"` PictureArts []PictureArt `json:"pictureArts" gorm:"foreignKey:Server,StoryID;reference:(Server,ID);constraint:OnDelete:CASCADE"` CharacterArts []CharacterArt `json:"characterArts" gorm:"foreignKey:Server,StoryID;reference:(Server,ID);constraint:OnDelete:CASCADE"` }
Click to show internal directories.
Click to hide internal directories.