Project

General

Profile

Actions

Bug #97352

open

Configuring module.tx_form in sitepackage throws exception due to wrong path in EXT:form ext_localconf.php

Added by Thorsten Weber almost 2 years ago. Updated almost 2 years ago.

Status:
New
Priority:
Should have
Assignee:
-
Category:
Form Framework
Target version:
Start date:
2022-04-09
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
11
PHP Version:
Tags:
Complexity:
easy
Is Regression:
Sprint Focus:
Remote Sprint

Description

What I did:
Followed some Documentations / Blogs for setting up a contact form
My goal was to have all form definitions in my sitepackage to save them in git.

I therefore build a form.typoscript

plugin.tx_form {
  settings {
    yamlConfigurations {
      100 = EXT:totos_sitepackage_instance/Configuration/TotoBarefoot/Yaml/TotoBarefootFormSetup.yaml
    }
  }
}

module.tx_form {
  settings {
    yamlConfigurations {
      100 = EXT:totos_sitepackage_instance/Configuration/TotoBarefoot/Yaml/TotoBarefootFormSetup.yaml
    }
  }
}

This loads correctly in as seen in Template Analyzer

TYPO3:
  CMS:
    Form:
      persistenceManager:
        allowedExtensionPaths:
          10: 'EXT:totos_sitepackage_instance/Configuration/TotoBarefoot/Yaml/Forms/form_definitions/'
          20: 'EXT:totos_sitepackage_instance/Resources/Private/TotoBarefoot/Forms/form_definitions/'
        allowSaveToExtensionPaths: true
        allowDeleteFromExtensionPaths: true
      prototypes:
        contactFormDefault:
          __inheritances:
            10: 'TYPO3.CMS.Form.prototypes.standard'
          formElementsDefinition:
            Form:
              renderingOptions:
                templateRootPaths:
                  20: 'EXT:totos_sitepackage_instance/Resources/Private/TotoBarefoot/Extensions/Form/Templates/Frontend/'
                partialRootPaths:
                  20: 'EXT:totos_sitepackage_instance/Resources/Private/TotoBarefoot/Extensions/Form/Partials/Frontend/'
                layoutRootPaths:
                  20: 'EXT:totos_sitepackage_instance/Resources/Private/TotoBarefoot/Extensions/Form/Layouts/Frontend/'

Now when I try to load the forms module or the configuration Module -> yaml Form settings
I will always see :

My research then found in EXT:form/ext_localconf.php in Lines 38-52

    // Add module configuration
    ExtensionManagementUtility::addTypoScriptSetup(
        'module.tx_form {
    settings {
        yamlConfigurations {
            10 = EXT:form/Configuration/Form/FormSetup.yaml
        }
    }
    view {
        templateRootPaths.10 = EXT:form/Resources/Private/Backend/Templates/
        partialRootPaths.10 = EXT:form/Resources/Private/Backend/Partials/
        layoutRootPaths.10 = EXT:form/Resources/Private/Backend/Layouts/
    }
}'
    );

The path set in Line 43 10 = EXT:form/Configuration/Form/FormSetup.yaml does not exist in Extension.

The exception does not appear as long as I do not try to overload the module settings
The exception does not appear if I fix the path in Line 43 to 10 = EXT:form/Configuration/Yaml/FormSetup.yaml which is existing.

As I am not familiar with PRs for Core Bugs I could use a hand here.


Files

Screenshot_20220409_201838.png (86.7 KB) Screenshot_20220409_201838.png Thorsten Weber, 2022-04-09 18:23
grafik.png (157 KB) grafik.png Thorsten Weber, 2022-04-09 18:27
Actions #1

Updated by Björn Jacob almost 2 years ago

  • Sprint Focus set to Remote Sprint
Actions #2

Updated by Elias Häußler almost 2 years ago

  • Description updated (diff)
Actions

Also available in: Atom PDF