@@ -118,16 +118,16 @@ How this looks when configuring the plugin:
118118.. index :: FlexForms; Display conditions
119119.. _flexformDisplayCond :
120120
121- Display fields conditionally (displayCond)
122- ------------------------------------------
121+ Display fields/sheets conditionally (displayCond)
122+ -------------------------------------------------
123123
124124Some settings may only make sense in the context of other settings.
125125For example, in one setting you define a sorting order (by date, title etc.)
126126and all sort orders except "title" have additional settings. These
127127are only visible if sort order "title" is not selected.
128128
129- You can define conditions using displayCond. This defines
130- whether a setting should be displayed when the plugin is configured.
129+ You can define conditions using displayCond. This defines whether a setting or
130+ sheet should be displayed when the plugin is configured.
131131It can depend on one or more settings in the FlexForm,
132132on database fields in the current record or be defined by a user function.
133133
@@ -139,6 +139,31 @@ on database fields in the current record or be defined by a user function.
139139 <!-- Hide field if value of neighbour field "settings.orderBy" on same sheet is not "title" -->
140140 <displayCond >FIELD:settings.orderBy:!=:title</displayCond >
141141
142+ .. code-block :: xml
143+
144+ <sheets >
145+ <sheetA >
146+ <ROOT >
147+ <sheetTitle >Sheet A</sheetTitle >
148+ <el >
149+ <settings .foo>
150+ ...
151+ </settings .foo>
152+ </el >
153+ </ROOT >
154+ </sheetA >
155+ <sheetB >
156+ <ROOT >
157+ <sheetTitle >Optional sheet B</sheetTitle >
158+ <!-- Hide entire sheet if value of field "foo" on neighboring sheet is not "bar" -->
159+ <displayCond >FIELD:sheetA.settings.foo:=:bar</displayCond >
160+ <el >
161+ ...
162+ </el >
163+ </ROOT >
164+ </sheetB >
165+ </sheets >
166+
142167 Again, the syntax and available fields and comparison operators is documented
143168in the TCA reference:
144169
0 commit comments