#99997Support disabling of flexform section object fields via PageTS TCEFORM
Description
It is currently possible to disable flexform fields via PageTS TCEFORM:
https://docs.typo3.org/m/typo3/reference-tsconfig/main/en-us/PageTsconfig/TceForm.html#disabled
This only works on the first level of flexform for the fields inside of sheets.
I suggest that this is extended to also be able to disable fields inside the structure of flexform.
When using the type “array” and section is set to “1” it is possible to add new items like with the “inline” field type.
My suggestion would be that it is possible to define the following PageTS config:
TCEFORM.tt_content.pi_flexform.my_ext_pi1.sDEF.myField.section.disabled = 1
TCEFORM.tt_content.pi_flexform.my_ext_pi1.sDEF.myField.section.sectionField.disabled = 1
I will add a patch with my proposed changes and new test cases.
Reviews 1
History 313
-
Justus Moroni changed description <span data-processor="relativetime" data-value="2023-02-20T17:58:38+00:00" > 02/20/23, 17:58 </span>
-
Gerrit Code Review pushed patch set 1 for main to change 77905 status
NewUnder Review <span data-processor="relativetime" data-value="2023-02-20T18:04:22+00:00" > 02/20/23, 18:04 </span> -
Gerrit Code Review pushed patch set 2 for main to change 77905 <span data-processor="relativetime" data-value="2023-10-18T08:42:53+00:00" > 10/18/23, 08:42 </span>
-
Gerrit Code Review pushed patch set 3 for main to change 77905 <span data-processor="relativetime" data-value="2023-10-18T08:44:42+00:00" > 10/18/23, 08:44 </span>
-
Gerrit Code Review pushed patch set 4 for main to change 77905 <span data-processor="relativetime" data-value="2023-10-18T09:00:02+00:00" > 10/18/23, 09:00 </span>
-
Gerrit Code Review pushed patch set 5 for main to change 77905 <span data-processor="relativetime" data-value="2023-10-18T09:20:15+00:00" > 10/18/23, 09:20 </span>
-
Gerrit Code Review pushed patch set 6 for main to change 77905 <span data-processor="relativetime" data-value="2025-01-21T15:29:07+00:00" > 01/21/25, 15:29 </span>
-
Gerrit Code Review pushed patch set 7 for main to change 77905 <span data-processor="relativetime" data-value="2025-03-26T09:35:52+00:00" > 03/26/25, 09:35 </span>
-
Gerrit Code Review pushed patch set 8 for main to change 77905 <span data-processor="relativetime" data-value="2025-03-27T16:15:39+00:00" > 03/27/25, 16:15 </span>
-
Stefan Bürk commented <span data-processor="relativetime" data-value="2025-04-12T12:19:35+00:00" > 04/12/25, 12:19 </span>
The linked gerrit change https://review.typo3.org/c/Packages/TYPO3.CMS/+/77905
on changeset 8 is way not ready and crash in some scenarios. On the one side,
these are technical issues and on the other hand the `user experience` needs to
be investigated and how to deal with these. Or better to say, define how it should
work for the user and what user expects and can expect.With the current state, following issue rises up:
- The `add section` button for a complete disabled (and removed) section is not
removed from the listing below the section field. Clicking sends a AJAX calls
which returns a exception (debug mode) and is not working related to retrieve
labels. - If all fields of a section is disabled and therefore removed, leaving a empty
section the same ajax error occurs and new elements are not creatable. Beside
the technical issue a empty section should be removed all together, which may
be doable in the current change as a second loop after the first removing loop.
Leading to the kept inoperable `add button` mentioned in the point above. - Assumend that the issues with the ajax call and the `add button` are handled,
the next point is what should happen with already selected/added items of the
disabled (removed) section type. Currently, they are also not displayed and
are not removed when persisting the record. That is good and bad, depending
on the point of view. Good, because they are not lost. For others bad as they
cannot be removed and still used/handled/displayed in the frontend (assuming
they are used to render stuff) leading to a confusion for editors which can’t
find the output in the record.
- The `add section` button for a complete disabled (and removed) section is not
-
Gerrit Code Review pushed patch set 9 for main to change 77905 <span data-processor="relativetime" data-value="2025-04-12T12:25:10+00:00" > 04/12/25, 12:25 </span>
-
Gerrit Code Review pushed patch set 10 for main to change 77905 <span data-processor="relativetime" data-value="2025-04-12T12:25:37+00:00" > 04/12/25, 12:25 </span>
Hey Justus,
check out https://extensions.typo3.org/extension/pagetsconfig – I hope this solves your problem.