genre

package
v0.0.0-...-2fe0e47 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 25, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IGenreRepo

type IGenreRepo interface {
	GetFilmGenres(filmId uint64) ([]models.GenreItem, error)
	GetGenreById(genreId uint64) (string, error)
	AddFilm(genres []uint64, filmId uint64) error
	UsersStatistics(idUser uint64) ([]requests.UsersStatisticsResponse, error)
}

type RepoPostgre

type RepoPostgre struct {
	// contains filtered or unexported fields
}

func GetGenreRepo

func GetGenreRepo(config *configs.DbDsnCfg, lg *slog.Logger) (*RepoPostgre, error)

func (*RepoPostgre) AddFilm

func (repo *RepoPostgre) AddFilm(genres []uint64, filmId uint64) error

func (*RepoPostgre) GetFilmGenres

func (repo *RepoPostgre) GetFilmGenres(filmId uint64) ([]models.GenreItem, error)

func (*RepoPostgre) GetGenreById

func (repo *RepoPostgre) GetGenreById(genreId uint64) (string, error)

func (*RepoPostgre) UsersStatistics

func (repo *RepoPostgre) UsersStatistics(idUser uint64) ([]requests.UsersStatisticsResponse, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL