Skip to content

HowToShareLayouts

Carlo Barazzetta edited this page Jan 27, 2017 · 1 revision

How to share the same layout between views

Layouts are yaml files stored under Metadata\Views\layouts, and by default they are searched for using a naming convention:

  • a layout called _List.yaml is automatically used by the Form controller to render a List view.
  • a layout called _Form.yaml is automatically used by the Form controller to render a Form view.

But, if you need to use a specify a layout in a View implement the MainTable/Controller/Grid/Layout or the MainTable/Controller/Form/layout parameters

For example:

MainTable:
...
  Controller:
...
    Form:
      Layout: XXXX_Form
    Grid:
      Layout: YYYY_Grid

You can also specify a layout for **details **implementing the MainTable/DetailTables/Table/Controller/Grid/Layout or the MainTable/DetailTables/Table/Controller/Form/layout parameters.

MainTable:
...
  DetailTables:
    Table:
      Controller:
        Form:
          Layout: ZZZZ_Form
Clone this wiki locally