postgres

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	CreatedAt time.Time
	UpdatedAt time.Time
)

Functions

func HandleDatabaseError

func HandleDatabaseError(err error, log *logger.Logger, message string) error

Types

type PostgresI

type PostgresI interface {
	TemplateCreate(ctx context.Context, req *models.TemplateCreateReq) (*models.TemplateResponse, error)
	TemplateGet(ctx context.Context, req *models.TemplateGetReq) (*models.TemplateResponse, error)
	TemplateFind(ctx context.Context, req *models.TemplateFindReq) (*models.TemplateFindResponse, error)
	TemplateUpdate(ctx context.Context, req *models.TemplateUpdateReq) (*models.TemplateResponse, error)
	TemplateDelete(ctx context.Context, req *models.TemplateDeleteReq) error
}

func New

func New(db *db.Postgres, log *logger.Logger, cfg *config.Config) PostgresI

Jump to

Keyboard shortcuts

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