mirror of
https://github.com/emo2007/block-accounting.git
synced 2025-04-12 08:56:28 +00:00
tmp
This commit is contained in:
parent
3ac070d12a
commit
3644ac7c9f
@ -2,13 +2,15 @@ package users
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
"database/sql"
|
||||||
|
|
||||||
"github.com/emochka2007/block-accounting/internal/pkg/models"
|
"github.com/emochka2007/block-accounting/internal/pkg/models"
|
||||||
|
"github.com/google/uuid"
|
||||||
)
|
)
|
||||||
|
|
||||||
type GetParams struct {
|
type GetParams struct {
|
||||||
Id string
|
Ids uuid.UUIDs
|
||||||
OrganizationId string
|
OrganizationId uuid.UUIDs
|
||||||
Seed []byte
|
Seed []byte
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -20,3 +22,31 @@ type Repository interface {
|
|||||||
Update(ctx context.Context, user *models.User) error
|
Update(ctx context.Context, user *models.User) error
|
||||||
Delete(ctx context.Context, id string) error
|
Delete(ctx context.Context, id string) error
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type repositorySQL struct {
|
||||||
|
db *sql.DB
|
||||||
|
}
|
||||||
|
|
||||||
|
func NewRepository(db *sql.DB) Repository {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (r *repositorySQL) Get(ctx context.Context, params GetParams) (*models.User, error) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
func (r *repositorySQL) Create(ctx context.Context, user *models.User) error {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
func (r *repositorySQL) Activate(ctx context.Context, id string) error {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
func (r *repositorySQL) Update(ctx context.Context, user *models.User) error {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
func (r *repositorySQL) Delete(ctx context.Context, id string) error {
|
||||||
|
|
||||||
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user