Pax.Plugins.DetailFieldsets (Pax v0.0.1-dev.20251023)
View SourceRenders fieldsets for the detail view of a Pax.Interface. Fieldsets are a way to organize a detail page, by breaking it into sections, and allowing fields to be grouped together on the same horizontal line.
There is a default fieldset called :default that is used when no fieldset is specified. The default fieldset is
rendered at the top of the page with no header. All other fieldsets will be rendered with a header above their
fields.
Options:
:placement- A list of sections where the fieldsets should be rendered. The default is[:show_body, :edit_body, :new_body].:fieldsets- A structure defining the fieldsets, fieldgroups, and their contained fields. This determines which fields to include, their organization, and the order to display them. The structure should be a list of tuples of the form{name, fieldgroups}wherenameis an atom or string andfieldgroupsis a list of fieldgroups.Each fieldgroup can be either:
- A list of field names (as atoms), which will be displayed together horizontally
- A single field name (as atom), which will be displayed on its own
If a field name is included that isn't available in the fields for that action, it will be skipped. If this option is not provided, all fields will be placed in the
:defaultfieldset, with each field in its own fieldgroup.Example:
[ default: [:name, :email], details: [ [:address, :city], :phone, [:created_at, :updated_at] ] ]
Summary
Functions
Callback implementation for Pax.Plugin.type/0.
Functions
Callback implementation for Pax.Plugin.type/0.