Versions in this module Expand all Collapse all v0 v0.1.4 Nov 12, 2026 v0.1.3 Nov 12, 2026 v0.1.2 Nov 11, 2026 Changes in this version + const MailAuthor + const MailWaiting type Repo + func (r *Repo) MailOff(ctx context.Context, userIDs []int) (map[int]bool, error) + func (r *Repo) SetMail(ctx context.Context, userID int, on bool) error v0.1.1 Nov 11, 2026 Changes in this version + const QueueSortAuthor + const QueueSortTitle + const QueueSortType + const QueueSortUpdated + type QueueItem struct + Updated time.Time + type QueueSort struct + Desc bool + Key string v0.1.0 Nov 5, 2026 Changes in this version + const DefaultLockMinutes + var Assets embed.FS + func RegisterRoutes(r modulekit.Mux, c *Controller, ...) + func Wire(d modulekit.Deps) modulekit.Parts + type Config struct + LockMinutes int + States []State + Transitions []Transition + Types []string + func (c Config) FirstPublished() string + func (c Config) Initial() State + func (c Config) State(name string) (State, bool) + func (c Config) Waiting() State + type Controller struct + func NewController(base *modulekit.BaseController, db *sql.DB, w *Workflow, ...) *Controller + func (c *Controller) KeepLock(w http.ResponseWriter, r *http.Request) + func (c *Controller) Queue(w http.ResponseWriter, r *http.Request) + func (c *Controller) ReleaseLock(w http.ResponseWriter, r *http.Request) + func (c *Controller) SaveSettings(w http.ResponseWriter, r *http.Request) + func (c *Controller) Settings(w http.ResponseWriter, r *http.Request) + func (c *Controller) TakeLock(w http.ResponseWriter, r *http.Request) + func (c *Controller) Transition(w http.ResponseWriter, r *http.Request) + func (c *Controller) TransitionPage(w http.ResponseWriter, r *http.Request) + type HistoryEntry struct + At time.Time + Comment string + From string + Nid int + To string + UID int + type Lock struct + LockedAt time.Time + Nid int + TouchedAt time.Time + UID int + type NodeState struct + ChangedAt time.Time + ChangedBy int + Nid int + State string + type Repo struct + func NewRepo(db *sql.DB) *Repo + func (r *Repo) AcquireLock(ctx context.Context, nid, uid int, now, since time.Time) (Lock, error) + func (r *Repo) AddHistory(ctx context.Context, h HistoryEntry) error + func (r *Repo) Backfill(ctx context.Context, types []string, states joinStates, now time.Time) ([]int, error) + func (r *Repo) Config(ctx context.Context) (Config, error) + func (r *Repo) Counts(ctx context.Context) (map[string]int, error) + func (r *Repo) History(ctx context.Context, nid, limit int) ([]HistoryEntry, error) + func (r *Repo) InState(ctx context.Context, state string, limit, offset int) ([]NodeState, int, error) + func (r *Repo) Lock(ctx context.Context, nid int) (Lock, bool, error) + func (r *Repo) Locks(ctx context.Context, ids []int, since time.Time) (map[int]Lock, error) + func (r *Repo) NodeState(ctx context.Context, nid int) (NodeState, bool, error) + func (r *Repo) ReleaseLock(ctx context.Context, nid, uid int) error + func (r *Repo) SaveConfig(ctx context.Context, cfg Config) error + func (r *Repo) SetNodeState(ctx context.Context, nid int, state string, uid int, now time.Time) error + func (r *Repo) States(ctx context.Context, ids []int) (map[int]NodeState, error) + func (r *Repo) TakeLock(ctx context.Context, nid, uid int, now time.Time) error + type State struct + Color string + ID int + Initial bool + Label string + Name string + Published bool + Weight int + func (s State) Hex() string + type Transition struct + Comment string + From []string + ID int + Label string + Roles []string + To string + Weight int + type Workflow struct + func NewWorkflow(repo *Repo, nodes modulekit.NodesRepository, auth modulekit.AuthService) *Workflow + func (w *Workflow) Allowed(ctx context.Context, user *modulekit.User, state string) ([]Transition, error) + func (w *Workflow) Config(ctx context.Context) (Config, error) + func (w *Workflow) Handles(ctx context.Context, contentType string) bool + func (w *Workflow) Make(ctx context.Context, node modulekit.Node, from State, t Transition, ...) error + func (w *Workflow) SaveConfig(ctx context.Context, db *sql.DB, cfg Config) error + func (w *Workflow) StateOf(ctx context.Context, node modulekit.Node) (State, error)