Documentation
¶
Overview ¶
Package orgkit is what the layer plugins (org-management, org-product, ...) share: records kept in the plugin's state, reading the units below through the unit's own org, and the exposure cards.
Index ¶
- func Card(r map[string]any) sdk.Node
- func Cards(c querier, child string, keep func(row map[string]any) bool) (*sdk.Node, error)
- func Children(c querier) ([]map[string]any, error)
- func Each(c querier, source string) []map[string]any
- func List(c state, k Kind) ([]map[string]any, error)
- func Records(p *sdk.Plugin, k Kind)
- func Rows(f *sdk.Frame) []map[string]any
- func Save(c state, user string, k Kind, a sdk.Args) (*sdk.Result, error)
- type Field
- type Kind
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Cards ¶
Cards renders what the units below expose to this one (child "*") or one child's, as a card each: a source's widget bound to org.unit.show, an action's form bound to org.unit.invoke. keep, when set, picks the exposures to show.
func Each ¶
Each is source (org.unit.kpis, org.unit.people, ...) of every reachable child, each row tagged with its unit.
Types ¶
type Kind ¶
type Kind struct {
Name, Plural, Title string
Fields []Field
// Derive adds computed columns (declared as Computed fields) to a row before it is listed.
Derive func(row map[string]any)
// Sort is a field to order by; a leading - sorts descending. Left out, the latest updated first.
Sort string
}
Kind is a record type: source <Plural> lists them, action <Name> creates, updates (id) or deletes (delete: true) one.