mirror of
https://github.com/IS1DI/x0gp.git
synced 2026-07-19 05:47:02 +00:00
Add graphify, tests and supabase migrations & config
This commit is contained in:
@@ -39,6 +39,18 @@ type Clan struct {
|
||||
UpdatedMs int64
|
||||
}
|
||||
|
||||
// Store defines the persistence operations for clans.
|
||||
type Store interface {
|
||||
Exec(ctx context.Context, sql string) (int64, error)
|
||||
Create(ctx context.Context, c Clan) error
|
||||
Get(ctx context.Context, id string) (Clan, error)
|
||||
GetByTag(ctx context.Context, tag string) (Clan, error)
|
||||
List(ctx context.Context, limit, offset int) ([]Clan, error)
|
||||
Delete(ctx context.Context, id string) error
|
||||
Update(ctx context.Context, c Clan) error
|
||||
Count(ctx context.Context) (int, error)
|
||||
}
|
||||
|
||||
// PgStore is the Postgres-backed half of the package.
|
||||
type PgStore struct {
|
||||
pool *pgxpool.Pool
|
||||
|
||||
Reference in New Issue
Block a user