Documentation ¶
Index ¶
- type Repository
- func (repo Repository) Create(thread models.Thread) (models.Thread, error)
- func (repo Repository) GetByID(id int32) (models.Thread, error)
- func (repo Repository) GetBySlug(slug string) (models.Thread, error)
- func (repo Repository) GetThreadsByForumSlug(forumSlug string, since *time.Time, desc bool, limit int32) (models.Threads, error)
- func (repo Repository) UpdateByID(thread models.Thread) (models.Thread, error)
- func (repo Repository) UpdateBySlug(thread models.Thread) (models.Thread, error)
- func (repo Repository) VoteByID(id int32, vote models.Vote) (thread models.Thread, err error)
- func (repo Repository) VoteBySlug(slug string, vote models.Vote) (thread models.Thread, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Repository ¶
type Repository struct {
// contains filtered or unexported fields
}
func NewRepository ¶
func NewRepository(db *pgxpool.Pool, forumRepo forum.Repository) Repository
func (Repository) GetThreadsByForumSlug ¶
func (Repository) UpdateByID ¶
func (Repository) UpdateBySlug ¶
func (Repository) VoteBySlug ¶
Click to show internal directories.
Click to hide internal directories.