Bug #99719
closedSaving an empty form leads to a defective yaml configuration
0%
Description
Steps to reproduce the issue¶
- In the forms mdoule create a new blank form, give it a name and click "finish!".
- In the now following mask: Edit nothing just click "save" and then close
- You now have created a defective yaml conf. When you download and look at the resulting yaml file you will see that it created an entry inside fieldState of the type "Page", but there is no form element of the type "Page", what will cause an error later.
renderingOptions: submitButtonLabel: Submit fieldState: page-1: type: Page identifier: page-1 label: Step renderingOptions: deleted: 1 listView: 1 type: Form identifier: testblankform label: 'Test blank form' prototypeName: standard renderables: - renderingOptions: previousButtonLabel: 'Previous step' nextButtonLabel: 'Next step' type: Page identifier: page-1 label: Step
The editor doesn't see that there is something off with the form config. They can continue to edit the form, set fields and finishers and implement the form into the web page.
When the editor later tries to check the form results in the "Form results" BE module they will recieve the following error:
#1327318156 TYPO3\CMS\Form\Domain\Exception\TypeDefinitionNotValidException
The "implementationClassName" for element "page-1" ("TYPO3\CMS\Form\Domain\Model\FormElements\Page") does not implement the FormElementInterface.
The form can be fixed by removing the faulty "page-1" entry in the YAML config. Also the form results can then be accesed without problems. But this is not a good solution, because it require server file acces priviliges and is inaccessible for normal editors.
Excpected behaviour¶
Saving an empty form should not result in a defective yaml config. (Don't save the step information inside the fieldState-node when there are no fields selected)
More Info¶
Operating system: Unix
PHP Version: 7.4.28
TYPO3 Version: 10.4.34
EXT:form Version: 10.4.34
EXT:form_to_database Version: 2.0.4
Files
Updated by Marcin Sągol about 1 year ago
I was unable to reproduce it on the 13-dev or 12.04 version.
The output generated on each version
13-dev
renderingOptions:
submitButtonLabel: Submit
type: Form
identifier: test
label: test
prototypeName: standard
renderables:
-
renderingOptions:
previousButtonLabel: 'Previous step'
nextButtonLabel: 'Next step'
type: Page
identifier: page-1
label: Step
12.04
renderingOptions:
submitButtonLabel: Submit
type: Form
identifier: test
label: test
prototypeName: standard
renderables:
-
renderingOptions:
previousButtonLabel: 'Previous step'
nextButtonLabel: 'Next step'
type: Page
identifier: page-1
label: Step
Updated by Thomas Balko about 1 year ago
I can confirm that this issue doesn't exist in TYPO3 versions 12+.
Also it seems that in TYPO3 11 the resulting yaml config doesn't create an error.
So the only problem remaining is in this specific TYPO3 10 version, but given that this problem doesn't persist in newer versions, I think the problem is too rare and too insignificant to justify a fix.
As far as I'm concerned, this ticket can be closed.
Thank you all for your time and effort.
Updated by Riccardo De Contardi 6 months ago
- Status changed from New to Closed
Thomas Balko , thank you for your answer and sorry for this very late reply.
I close this issue in agreement with the reporter
If you think that this is the wrong decisionor there is still work to do here, please reopen it or open a new issue with a reference to this one.
Thank you