Documentation
¶
Index ¶
- type JSONRaw
- type NullTimestamp
- type SQLiteBool
- type Store
- func (s *Store) ActorGet(ctx context.Context, name string) (model.Actor, error)
- func (s *Store) ActorGetByAPIKeyHash(ctx context.Context, hash string) (model.Actor, error)
- func (s *Store) ActorInsert(ctx context.Context, tx repo.Tx, actor model.Actor) (model.Actor, error)
- func (s *Store) ActorList(ctx context.Context) ([]model.Actor, error)
- func (s *Store) ActorUpdate(ctx context.Context, tx repo.Tx, params model.UpdateActorParams) (model.Actor, error)
- func (s *Store) ActorUpdateKeyHash(ctx context.Context, name, newHash string) error
- func (s *Store) AttachmentDelete(ctx context.Context, tx repo.Tx, id int) error
- func (s *Store) AttachmentGet(ctx context.Context, id int) (model.Attachment, error)
- func (s *Store) AttachmentInsert(ctx context.Context, tx repo.Tx, att model.Attachment) (model.Attachment, error)
- func (s *Store) AttachmentList(ctx context.Context, boardSlug string, taskNum int) ([]model.Attachment, error)
- func (s *Store) AttachmentUpdateTaskRef(ctx context.Context, tx repo.Tx, oldBoard string, oldNum int, newBoard string, ...) error
- func (s *Store) AuditInsert(ctx context.Context, tx repo.Tx, entry model.AuditEntry) error
- func (s *Store) AuditQueryByBoard(ctx context.Context, boardSlug string) ([]model.AuditEntry, error)
- func (s *Store) AuditQueryByTask(ctx context.Context, boardSlug string, taskNum int) ([]model.AuditEntry, error)
- func (s *Store) AuditUpdateTaskRef(ctx context.Context, tx repo.Tx, oldBoard string, oldNum int, newBoard string, ...) error
- func (s *Store) BoardAllocateTaskNum(ctx context.Context, tx repo.Tx, slug string) (int, error)
- func (s *Store) BoardGet(ctx context.Context, slug string) (model.Board, error)
- func (s *Store) BoardInsert(ctx context.Context, tx repo.Tx, board model.Board) (model.Board, error)
- func (s *Store) BoardList(ctx context.Context, params model.ListBoardsParams) ([]model.Board, error)
- func (s *Store) BoardSetDeleted(ctx context.Context, tx repo.Tx, slug string) error
- func (s *Store) BoardSetWorkflow(ctx context.Context, tx repo.Tx, slug string, wf json.RawMessage) error
- func (s *Store) BoardUpdate(ctx context.Context, tx repo.Tx, params model.UpdateBoardParams) (model.Board, error)
- func (s *Store) BoardUpdateNextTaskNum(ctx context.Context, tx repo.Tx, slug string, nextNum int) error
- func (s *Store) Close() error
- func (s *Store) CommentGet(ctx context.Context, id int) (model.Comment, error)
- func (s *Store) CommentInsert(ctx context.Context, tx repo.Tx, comment model.Comment) (model.Comment, error)
- func (s *Store) CommentList(ctx context.Context, boardSlug string, taskNum int) ([]model.Comment, error)
- func (s *Store) CommentUpdateBody(ctx context.Context, tx repo.Tx, id int, body string) (model.Comment, error)
- func (s *Store) CommentUpdateTaskRef(ctx context.Context, tx repo.Tx, oldBoard string, oldNum int, newBoard string, ...) error
- func (s *Store) DependencyDelete(ctx context.Context, tx repo.Tx, id int) error
- func (s *Store) DependencyGet(ctx context.Context, id int) (model.Dependency, error)
- func (s *Store) DependencyInsert(ctx context.Context, tx repo.Tx, dep model.Dependency) (model.Dependency, error)
- func (s *Store) DependencyList(ctx context.Context, boardSlug string, taskNum int) ([]model.Dependency, error)
- func (s *Store) DependencyUpdateTaskRefs(ctx context.Context, tx repo.Tx, oldBoard string, oldNum int, newBoard string, ...) error
- func (s *Store) InTransaction(ctx context.Context, fn func(tx repo.Tx) error) error
- func (s *Store) TaskDeleteByBoardAndNums(ctx context.Context, tx repo.Tx, boardSlug string, nums []int) error
- func (s *Store) TaskGet(ctx context.Context, boardSlug string, num int) (model.Task, error)
- func (s *Store) TaskInsert(ctx context.Context, tx repo.Tx, task model.Task) (model.Task, error)
- func (s *Store) TaskList(ctx context.Context, filter model.TaskFilter, sort *model.TaskSort) ([]model.Task, error)
- func (s *Store) TaskListTags(ctx context.Context, boardSlug string) ([]model.TagCount, error)
- func (s *Store) TaskSetDeleted(ctx context.Context, tx repo.Tx, boardSlug string, num int) error
- func (s *Store) TaskUpdate(ctx context.Context, tx repo.Tx, params model.UpdateTaskParams) (model.Task, error)
- func (s *Store) WebhookDelete(ctx context.Context, tx repo.Tx, id int) error
- func (s *Store) WebhookDeliveryInsert(ctx context.Context, d model.WebhookDelivery) (model.WebhookDelivery, error)
- func (s *Store) WebhookDeliveryList(ctx context.Context, webhookID int) ([]model.WebhookDelivery, error)
- func (s *Store) WebhookGet(ctx context.Context, id int) (model.Webhook, error)
- func (s *Store) WebhookInsert(ctx context.Context, tx repo.Tx, webhook model.Webhook) (model.Webhook, error)
- func (s *Store) WebhookList(ctx context.Context) ([]model.Webhook, error)
- func (s *Store) WebhookUpdate(ctx context.Context, tx repo.Tx, params model.UpdateWebhookParams) (model.Webhook, error)
- type StringList
- type Timestamp
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type JSONRaw ¶
type JSONRaw json.RawMessage
JSONRaw handles SQLite TEXT ↔ json.RawMessage. json.RawMessage's built-in Scanner only handles []byte, not string.
type NullTimestamp ¶
NullTimestamp handles nullable SQLite TEXT timestamp ↔ Go *time.Time.
func (*NullTimestamp) Scan ¶
func (t *NullTimestamp) Scan(src any) error
func (NullTimestamp) TimePtr ¶
func (t NullTimestamp) TimePtr() *time.Time
type SQLiteBool ¶
type SQLiteBool bool
SQLiteBool handles SQLite INTEGER (0/1) ↔ Go bool conversion.
func (*SQLiteBool) Scan ¶
func (b *SQLiteBool) Scan(src any) error
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
func New ¶
New opens (or creates) a SQLite database and runs migrations. For file-backed databases, pass a path like "./taskflow.db". For in-memory databases (testing), pass ":memory:".
func (*Store) ActorGetByAPIKeyHash ¶
func (*Store) ActorInsert ¶
func (*Store) ActorUpdate ¶
func (*Store) ActorUpdateKeyHash ¶
func (*Store) AttachmentDelete ¶
func (*Store) AttachmentGet ¶
func (*Store) AttachmentInsert ¶
func (s *Store) AttachmentInsert(ctx context.Context, tx repo.Tx, att model.Attachment) (model.Attachment, error)
func (*Store) AttachmentList ¶
func (*Store) AttachmentUpdateTaskRef ¶
func (*Store) AuditInsert ¶
func (*Store) AuditQueryByBoard ¶
func (*Store) AuditQueryByTask ¶
func (*Store) AuditUpdateTaskRef ¶
func (*Store) BoardAllocateTaskNum ¶
func (*Store) BoardInsert ¶
func (*Store) BoardSetDeleted ¶
func (*Store) BoardSetWorkflow ¶
func (*Store) BoardUpdate ¶
func (*Store) BoardUpdateNextTaskNum ¶
func (*Store) CommentGet ¶
func (*Store) CommentInsert ¶
func (*Store) CommentList ¶
func (*Store) CommentUpdateBody ¶
func (*Store) CommentUpdateTaskRef ¶
func (*Store) DependencyDelete ¶
func (*Store) DependencyGet ¶
func (*Store) DependencyInsert ¶
func (s *Store) DependencyInsert(ctx context.Context, tx repo.Tx, dep model.Dependency) (model.Dependency, error)
func (*Store) DependencyList ¶
func (*Store) DependencyUpdateTaskRefs ¶
func (*Store) InTransaction ¶
func (*Store) TaskDeleteByBoardAndNums ¶
func (*Store) TaskInsert ¶
func (*Store) TaskListTags ¶
func (*Store) TaskSetDeleted ¶
func (*Store) TaskUpdate ¶
func (*Store) WebhookDelete ¶
func (*Store) WebhookDeliveryInsert ¶
func (s *Store) WebhookDeliveryInsert(ctx context.Context, d model.WebhookDelivery) (model.WebhookDelivery, error)
func (*Store) WebhookDeliveryList ¶
func (*Store) WebhookGet ¶
func (*Store) WebhookInsert ¶
func (*Store) WebhookList ¶
type StringList ¶
type StringList []string
StringList handles SQLite JSON TEXT ↔ Go []string conversion.
func (*StringList) Scan ¶
func (s *StringList) Scan(src any) error
Click to show internal directories.
Click to hide internal directories.