ms-auth/internal/users/pg_repository.go
Vyacheslav1557 93eaf89d78 refactor:
2024-10-09 22:07:38 +05:00

16 lines
513 B
Go

package users
import (
"context"
"git.sch9.ru/new_gate/ms-auth/internal/models"
)
type PgRepository interface {
CreateUser(ctx context.Context, user *models.User) (int32, error)
ReadUserByEmail(ctx context.Context, email string) (*models.User, error)
ReadUserByUsername(ctx context.Context, username string) (*models.User, error)
ReadUserById(ctx context.Context, id int32) (*models.User, error)
UpdateUser(ctx context.Context, user *models.User) error
DeleteUser(ctx context.Context, id int32) error
}