Bug #86056

Form yaml predefinedDefaults renderingOptions are not being set at form creation

Added by Jurian Janssen 6 months ago. Updated 21 days ago.

Status:
New
Priority:
Should have
Category:
Form Framework
Target version:
-
Start date:
2018-08-31
Due date:
% Done:

0%

TYPO3 Version:
8
PHP Version:
7.2
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

I have the following in my yaml configuration file

     prototypes:
       mautic:
          formElementsDefinition:
            Form:
              renderingOptions:
                partialRootPaths:
                    1486978514: 'EXT:marketing_automation_mautic/Resources/Private/Frontend/Partials'
              formEditor:
                predefinedDefaults:
                  renderingOptions:
                    mauticFormType: 'mautic_finisher_standalone_prototype'

However, when creating a form 'mauticFormType' is never set to the default value and is simply absent.

History

#1 Updated by Ralf Zimmermann 21 days ago

  • Assignee set to Jurian Janssen
TYPO3:
  CMS:
    Form:
      formManager:
        selectablePrototypesConfiguration:
          200:
            identifier: 'test'
            label: 'test'
            newFormTemplates:
              100:
                templatePath: 'EXT:form/Resources/Private/Backend/Templates/FormEditor/Yaml/NewForms/BlankForm.yaml'
                label: 'formManager.selectablePrototypesConfiguration.standard.newFormTemplates.blankForm.label'
              200:
                templatePath: 'EXT:form/Resources/Private/Backend/Templates/FormEditor/Yaml/NewForms/SimpleContactForm.yaml'
                label: 'formManager.selectablePrototypesConfiguration.standard.newFormTemplates.simpleContactForm.label'
      prototypes:
        test:
          __inheritances:
            10: 'TYPO3.CMS.Form.prototypes.standard'
          formElementsDefinition:
            Form:
              formEditor:
                predefinedDefaults:
                  renderingOptions:
                    mauticFormType: 'mautic_finisher_standalone_prototype'

Works for me with TYPO3 8.7.25-dev and TYPO3 9.5.5-dev.
Note that if you create a new form, the predefinedDefaults values are written after a klick on the save button.
If you want the renderingOptions... predefinedDefaults also be available directely after the form creation, you have to define a boilerplate form definition template (https://docs.typo3.org/typo3cms/extensions/form/Concepts/FormManager/Index.html#start-templates) or maybe you can set this values through a hook https://docs.typo3.org/typo3cms/extensions/form/ApiReference/Index.html?highlight=beforeformcreate#beforeformcreate

Also available in: Atom PDF