You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(form): render object fieldGroups in create/edit modal; auto-layout parity for grouped ObjectForm (#2152) (#2154)
ModalForm ignored the object's fieldGroups designer metadata entirely —
the global create modal rendered grouped objects as one flat field pile.
ObjectForm's grouped path bypassed applyAutoLayout: no system-field
filtering, always single column, hairline group titles on an endlessly
scrolling form.
- ModalForm: when no explicit sections/customFields are passed, derive
sections from objectSchema.fieldGroups + field.group (same
deriveFieldGroupSections as ObjectForm), with flat-path auto-layout
parity: system/auto-generated fields filtered, columns inferred from
field count, wide fields spanning the row, modal size auto-upgraded
for multi-column. Explicit curated sections always win.
- The derived groups render as ONE form with virtual section-divider
fields (DrawerForm's pattern) — NOT one SchemaRenderer per section.
Per-section renderers create N <form> elements sharing the footer
button's form id, so only the first section's values ever submit
(verified live: group 2's required status showed a value in the UI
but was absent from the POST body → VALIDATION_FAILED). That latent
flaw still affects the explicit-sections path; tracked in #2153.
- ModalForm's flat field builder now carries Field.group so derivation
sees group membership; section headers go through sectionLabel i18n.
- ObjectForm grouped path: filter system/auto-generated fields, infer
columns, applyAutoColSpan, container-query grid — matching the flat
path.
Verified against a real console (:5180) + real hotcrm backend (:4001):
crm_campaign_member (fieldGroups, no form view) modal now shows both
group headers in a 2-column xl dialog, and a cross-group create submits
all values (record persisted, POST body contains every group's fields).
crm_lead's explicit "Quick Lead Creation" view renders and submits
unchanged. plugin-form: 155/155 tests, type-check green.
Closes#2152
0 commit comments