Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var TaskMeta = drel.ModelMeta[Task]{ Table: "tasks", Columns: []string{"id", "title", "done", "priority", "created_at", "updated_at"}, PKColumn: "id", Scan: scanTask, Snapshot: snapshotTask, Diff: diffTask, PKValue: taskPKValue, InsertColumns: taskInsertColumns, ScanReturning: taskScanReturning, ColumnValue: taskColumnValue, NormalizeKey: taskNormalizeKey, }
View Source
var Tasks = struct { ID drel.OrderedColumn[int] Title drel.StringColumn Done drel.BoolColumn Priority drel.OrderedColumn[int] CreatedAt drel.TimeColumn UpdatedAt drel.TimeColumn }{ ID: drel.NewOrderedCol[int]("id"), Title: drel.NewStringCol("title"), Done: drel.NewBoolCol("done"), Priority: drel.NewOrderedCol[int]("priority"), CreatedAt: drel.NewTimeCol("created_at"), UpdatedAt: drel.NewTimeCol("updated_at"), }
Functions ¶
This section is empty.
Types ¶
type Task ¶
type Task struct {
drel.Model[int]
Title string `db:"title"`
Done bool `db:"done"`
Priority int `db:"priority"`
}
func (*Task) SetPriority ¶
type TaskRepository ¶
type TaskRepository struct {
*drel.Repository[Task]
}
type TxTaskRepository ¶
type TxTaskRepository struct {
*drel.TxRepository[Task]
}
type UoWTaskRepository ¶ added in v0.3.0
type UoWTaskRepository struct {
*drel.UoWRepository[Task]
}
Click to show internal directories.
Click to hide internal directories.