feat(32-01): cross-plugin admin form extensions (tracer)
- pact.AdminActionExtension.Form with AdminFormExtension: a fields document (fields.yaml format plus before:/after:/zone: and a tabs: list) given as an AdminFS path or YAML bytes, Load and Save hooks, AdminFormLoad/Save/SaveResult, AdminFormErrors and zone constants - cabana compileFormExtensions places extension fields at owner anchors at boot, regrouping an extended form by tab - save lifts extension values before any owner path and runs Save in the record's transaction after the owner row; show merges Load - TestFormExtensionTracer: c after a on a, b gives a, c, b through the admin API, stored in the contributor's table
This commit is contained in:
@@ -256,6 +256,12 @@ type CompiledController struct {
|
||||
// singleton is true for a controller implementing pact.AdminSingleton
|
||||
// (D-11): one record, opened directly; no list, create, bulk or delete.
|
||||
singleton bool
|
||||
// formExtensions are the form contributions other plugins (or the owner)
|
||||
// add through pact.AdminActionExtension.Form (D-91), in plugin activation
|
||||
// order; extensionFields maps the name of every field they add to its
|
||||
// extension.
|
||||
formExtensions []*compiledFormExtension
|
||||
extensionFields map[string]*compiledFormExtension
|
||||
}
|
||||
|
||||
// Registry is the immutable controller map keyed by controller ID.
|
||||
|
||||
Reference in New Issue
Block a user