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:
2026-10-26 21:46:43 +01:00
parent 9868838fe3
commit 0819442634
8 changed files with 1150 additions and 6 deletions

View File

@@ -114,6 +114,12 @@ func Activate(app *backpack.App, plugins []party.Plugin) (*Routes, error) {
if err != nil {
return nil, err
}
// D-91: fields and tabs other plugins add to a controller's form are
// placed once every form is compiled, before any later pass reads the
// forms.
if err := compileFormExtensions(reg, plugins); err != nil {
return nil, err
}
uploadBytes, err := configBytes(app, "http.body_limits.upload_bytes")
if err != nil {
return nil, err