Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Balance ¶
type BalanceRequest ¶
type Repository ¶
type Repository interface { List(ctx context.Context, ticketer string, limit, offset int64) ([]Ticket, error) Updates(ctx context.Context, req UpdatesRequest) ([]TicketUpdate, error) UpdatesForOperation(ctx context.Context, operationId int64) ([]TicketUpdate, error) BalancesForAccount(ctx context.Context, accountId int64, req BalanceRequest) ([]Balance, error) }
type Ticket ¶
type Ticket struct { bun.BaseModel `bun:"tickets"` ID int64 `bun:"id,pk,notnull,autoincrement"` Level int64 `bun:"level"` TicketerID int64 `bun:"ticketer_id"` ContentType []byte `bun:"content_type,type:bytea"` Content []byte `bun:"content,type:bytea"` UpdatesCount int `bun:"updates_count"` Hash string `bun:"hash,unique:ticket_key"` Ticketer account.Account `bun:"rel:belongs-to"` }
type TicketUpdate ¶
type TicketUpdate struct { bun.BaseModel `bun:"ticket_updates"` ID int64 `bun:"id,pk,notnull,autoincrement"` Timestamp time.Time `bun:"timestamp,pk,notnull"` OperationId int64 `bun:"operation_id"` Level int64 `bun:"level"` TicketId int64 `bun:"ticket_id"` AccountId int64 `bun:"account_id"` Amount decimal.Decimal `bun:"amount,type:numeric(200,0)"` Account account.Account `bun:"rel:belongs-to"` Ticket Ticket `bun:"rel:belongs-to"` }
TicketUpdate -
func (*TicketUpdate) LogFields ¶
func (t *TicketUpdate) LogFields() map[string]interface{}
LogFields -
func (TicketUpdate) TableName ¶
func (TicketUpdate) TableName() string
Click to show internal directories.
Click to hide internal directories.