repo

package
v0.0.0-...-6c9f955 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type UserRepository

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

UserRepository wraps generated query functions with a repository pattern.

func NewUserRepository

func NewUserRepository(db orm.Querier) *UserRepository

func (*UserRepository) Create

func (r *UserRepository) Create(ctx context.Context, u *model.User) error

func (*UserRepository) Delete

func (r *UserRepository) Delete(ctx context.Context, id int) error

func (*UserRepository) FindAll

func (r *UserRepository) FindAll(ctx context.Context, scopes ...scope.Scope) ([]model.User, error)

func (*UserRepository) FindByID

func (r *UserRepository) FindByID(ctx context.Context, id int) (model.User, error)

func (*UserRepository) Update

func (r *UserRepository) Update(ctx context.Context, u *model.User) error

Jump to

Keyboard shortcuts

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