postgresrepository

package
v0.0.0-...-ab8551a Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewPostgreDB

func NewPostgreDB(cfg *repository.DBConfig) (*sqlx.DB, error)

Types

type CinemaRepository

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

func NewCinemaRepository

func NewCinemaRepository(logger *logrus.Logger, db *sqlx.DB) *CinemaRepository

func (*CinemaRepository) GetAllMoviesScreenings

func (r *CinemaRepository) GetAllMoviesScreenings(ctx context.Context,
	startPeriod, endPeriod time.Time) (screenings []models.MoviesScreenings, err error)

func (*CinemaRepository) GetCinema

func (r *CinemaRepository) GetCinema(ctx context.Context, id int32) (cinema models.Cinema, err error)

func (*CinemaRepository) GetCinemasCities

func (r *CinemaRepository) GetCinemasCities(ctx context.Context) (cities []models.City, err error)

func (*CinemaRepository) GetCinemasInCity

func (r *CinemaRepository) GetCinemasInCity(ctx context.Context, id int32) (cinemas []models.Cinema, err error)

func (*CinemaRepository) GetCityScreenings

func (r *CinemaRepository) GetCityScreenings(ctx context.Context,
	cityID, movieID int32, startPeriod, endPeriod time.Time) (screenings []models.CityScreening, err error)

func (*CinemaRepository) GetHallConfiguraion

func (r *CinemaRepository) GetHallConfiguraion(ctx context.Context, id int32) (places []models.Place, err error)

func (*CinemaRepository) GetHalls

func (r *CinemaRepository) GetHalls(ctx context.Context, ids []int32) (halls []models.Hall, err error)

func (*CinemaRepository) GetMoviesScreenings

func (r *CinemaRepository) GetMoviesScreenings(ctx context.Context,
	cinemaID int32, startPeriod, endPeriod time.Time) (screenings []models.MoviesScreenings, err error)

func (*CinemaRepository) GetMoviesScreeningsInCities

func (r *CinemaRepository) GetMoviesScreeningsInCities(ctx context.Context,
	citiesIDs []int32, startPeriod, endPeriod time.Time) (screenings []models.MoviesScreenings, err error)

func (*CinemaRepository) GetScreening

func (r *CinemaRepository) GetScreening(ctx context.Context, id int64) (screening models.Screening, err error)

func (*CinemaRepository) GetScreenings

func (r *CinemaRepository) GetScreenings(ctx context.Context,
	cinemaID, movieID int32, startPeriod, endPeriod time.Time) (screenings []models.Screening, err error)

Jump to

Keyboard shortcuts

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