postgres

package
v0.20.0 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2026 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Migration

func Migration() (*migrate.MemoryMigrationSource, error)

func NewDuplicateErrors added in v0.18.4

func NewDuplicateErrors() errors.Mapper

func NewRepository

func NewRepository(db postgres.Database) reports.Repository

Types

type PostgresRepository

type PostgresRepository struct {
	DB postgres.Database

	rolesPostgres.Repository
	// contains filtered or unexported fields
}

func (*PostgresRepository) AddReportConfig

func (repo *PostgresRepository) AddReportConfig(ctx context.Context, cfg reports.ReportConfig) (reports.ReportConfig, error)

func (*PostgresRepository) DeleteReportTemplate

func (repo *PostgresRepository) DeleteReportTemplate(ctx context.Context, domainID, reportID string) error

func (*PostgresRepository) ListAllReportsConfig added in v0.19.1

func (repo *PostgresRepository) ListAllReportsConfig(ctx context.Context, pm reports.PageMeta) (reports.ReportConfigPage, error)

func (*PostgresRepository) ListUserReportsConfig added in v0.19.1

func (repo *PostgresRepository) ListUserReportsConfig(ctx context.Context, userID string, pm reports.PageMeta) (reports.ReportConfigPage, error)

func (*PostgresRepository) RemoveReportConfig

func (repo *PostgresRepository) RemoveReportConfig(ctx context.Context, id string) error

func (*PostgresRepository) RetrieveByIDWithRoles added in v0.19.1

func (repo *PostgresRepository) RetrieveByIDWithRoles(ctx context.Context, id, memberID string) (reports.ReportConfig, error)

func (*PostgresRepository) UpdateReportConfig

func (repo *PostgresRepository) UpdateReportConfig(ctx context.Context, cfg reports.ReportConfig) (reports.ReportConfig, error)

func (*PostgresRepository) UpdateReportConfigStatus

func (repo *PostgresRepository) UpdateReportConfigStatus(ctx context.Context, cfg reports.ReportConfig) (reports.ReportConfig, error)

func (*PostgresRepository) UpdateReportDue

func (repo *PostgresRepository) UpdateReportDue(ctx context.Context, id string, due time.Time) (reports.ReportConfig, error)

func (*PostgresRepository) UpdateReportSchedule

func (repo *PostgresRepository) UpdateReportSchedule(ctx context.Context, cfg reports.ReportConfig) (reports.ReportConfig, error)

func (*PostgresRepository) UpdateReportTemplate

func (repo *PostgresRepository) UpdateReportTemplate(ctx context.Context, domainID, reportID string, template reports.ReportTemplate) error

func (*PostgresRepository) ViewReportConfig

func (repo *PostgresRepository) ViewReportConfig(ctx context.Context, id string) (reports.ReportConfig, error)

func (*PostgresRepository) ViewReportTemplate

func (repo *PostgresRepository) ViewReportTemplate(ctx context.Context, domainID, reportID string) (reports.ReportTemplate, error)

Jump to

Keyboard shortcuts

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