feat: add wallet settlement audit flow

This commit is contained in:
2026-05-11 22:59:26 +08:00
parent da1e19d0a9
commit c992f1de60
22 changed files with 1452 additions and 44 deletions
+19
View File
@@ -0,0 +1,19 @@
package store
import (
"context"
"github.com/jackc/pgx/v5"
"github.com/jackc/pgx/v5/pgconn"
)
type Tx interface {
Exec(ctx context.Context, sql string, arguments ...any) (pgconn.CommandTag, error)
QueryRow(ctx context.Context, sql string, args ...any) pgx.Row
}
func (s *Store) InTx(ctx context.Context, fn func(Tx) error) error {
return pgx.BeginFunc(ctx, s.pool, func(tx pgx.Tx) error {
return fn(tx)
})
}