Documentation
¶
Index ¶
- func Migration() (*migrate.MemoryMigrationSource, error)
- func NewDuplicateErrors() errors.Mapper
- func NewRepository(db postgres.Database) reports.Repository
- type PostgresRepository
- func (repo *PostgresRepository) AddReportConfig(ctx context.Context, cfg reports.ReportConfig) (reports.ReportConfig, error)
- func (repo *PostgresRepository) DeleteReportTemplate(ctx context.Context, domainID, reportID string) error
- func (repo *PostgresRepository) ListAllReportsConfig(ctx context.Context, pm reports.PageMeta) (reports.ReportConfigPage, error)
- func (repo *PostgresRepository) ListUserReportsConfig(ctx context.Context, userID string, pm reports.PageMeta) (reports.ReportConfigPage, error)
- func (repo *PostgresRepository) RemoveReportConfig(ctx context.Context, id string) error
- func (repo *PostgresRepository) RetrieveByIDWithRoles(ctx context.Context, id, memberID string) (reports.ReportConfig, error)
- func (repo *PostgresRepository) UpdateReportConfig(ctx context.Context, cfg reports.ReportConfig) (reports.ReportConfig, error)
- func (repo *PostgresRepository) UpdateReportConfigStatus(ctx context.Context, cfg reports.ReportConfig) (reports.ReportConfig, error)
- func (repo *PostgresRepository) UpdateReportDue(ctx context.Context, id string, due time.Time) (reports.ReportConfig, error)
- func (repo *PostgresRepository) UpdateReportSchedule(ctx context.Context, cfg reports.ReportConfig) (reports.ReportConfig, error)
- func (repo *PostgresRepository) UpdateReportTemplate(ctx context.Context, domainID, reportID string, ...) error
- func (repo *PostgresRepository) ViewReportConfig(ctx context.Context, id string) (reports.ReportConfig, error)
- func (repo *PostgresRepository) ViewReportTemplate(ctx context.Context, domainID, reportID string) (reports.ReportTemplate, error)
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 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)
Click to show internal directories.
Click to hide internal directories.