Documentation ¶
Overview ¶
Package postgres contains the database implementation of clients repository layer.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Repository ¶
type Repository interface { mgclients.Repository // Save persists the client account. A non-nil error is returned to indicate // operation failure. Save(ctx context.Context, client mgclients.Client) (mgclients.Client, error) RetrieveByID(ctx context.Context, id string) (mgclients.Client, error) UpdateRole(ctx context.Context, client mgclients.Client) (mgclients.Client, error) CheckSuperAdmin(ctx context.Context, adminID string) error }
Repository defines the required dependencies for Client repository.
func NewRepository ¶
func NewRepository(db postgres.Database) Repository
NewRepository instantiates a PostgreSQL implementation of Clients repository.
Click to show internal directories.
Click to hide internal directories.