Bug #83985

Faulty YAML property for empty array

Added by Oliver Hader over 1 year ago. Updated 11 months ago.

Status:
Closed
Priority:
Should have
Category:
Form Framework
Target version:
-
Start date:
2018-02-20
Due date:
% Done:

100%

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

Description

Scenario:
  • create new form
  • add new text element
  • define placeholder value (not empty)
  • save form
  • clear placeholder (now use empty value)
  • save form

Result in generate YAML file:


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
    renderables:
      -
        defaultValue: ''
        type: Text
        identifier: text-1
        label: Text
        properties:
          fluidAdditionalAttributes: {  }

Description:
fluidAdditionalAttributes: { } gets written YAML which should represent an empty array. It has to be determined, where this { } notation is coming from.

Not tested yet in TYPO3 v8.

Associated revisions

Revision 97582e4d (diff)
Added by Ralf Zimmermann over 1 year ago

[BUGFIX] Do not write empty array values in form definitions

Symfony YAML dumps empty arrays as sequence ("{ }"). Due to this, some
JavaScript modules of the form framework fail to interpret/ set the
correct data type for those properties.

If applied, this commit will ensure that the formEditor unsets empty
array keys on load/ save.

The problem only affects the backend module, not the frontend
formDefinition interpreter.

Resolves: #83985
Releases: master, 8.7
Change-Id: I913b8954790510b4ffcc80a47f9dbb7646239ff1
Reviewed-on: https://review.typo3.org/55848
Tested-by: TYPO3com <>
Reviewed-by: Björn Jacob <>
Tested-by: Björn Jacob <>
Reviewed-by: Kay Strobach <>
Tested-by: Kay Strobach <>
Reviewed-by: Frank Naegler <>
Tested-by: Frank Naegler <>

Revision ca582481 (diff)
Added by Ralf Zimmermann over 1 year ago

[BUGFIX] Do not write empty array values in form definitions

Symfony YAML dumps empty arrays as sequence ("{ }"). Due to this, some
JavaScript modules of the form framework fail to interpret/ set the
correct data type for those properties.

If applied, this commit will ensure that the formEditor unsets empty
array keys on load/ save.

The problem only affects the backend module, not the frontend
formDefinition interpreter.

Resolves: #83985
Releases: master, 8.7
Change-Id: I913b8954790510b4ffcc80a47f9dbb7646239ff1
Reviewed-on: https://review.typo3.org/55848
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Björn Jacob <bjoern.jacob@tritum.de>
Tested-by: Björn Jacob <bjoern.jacob@tritum.de>
Reviewed-by: Kay Strobach <typo3@kay-strobach.de>
Tested-by: Kay Strobach <typo3@kay-strobach.de>
Reviewed-by: Frank Naegler <frank.naegler@typo3.org>
Tested-by: Frank Naegler <frank.naegler@typo3.org>
Reviewed-on: https://review.typo3.org/56744
Reviewed-by: Oliver Hader <>
Tested-by: Oliver Hader <>

History

#1 Updated by Ralf Zimmermann over 1 year ago

  • Assignee set to Ralf Zimmermann
  • TYPO3 Version changed from 9 to 8

#2 Updated by Gerrit Code Review over 1 year ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/55848

#3 Updated by Gerrit Code Review over 1 year ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/55848

#4 Updated by Bjoern Jacob over 1 year ago

  • Sprint Focus set to Remote Sprint

#5 Updated by Gerrit Code Review over 1 year ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/55848

#6 Updated by Gerrit Code Review over 1 year ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/55848

#7 Updated by Gerrit Code Review over 1 year ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/55848

#8 Updated by Gerrit Code Review over 1 year ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/55848

#9 Updated by Gerrit Code Review over 1 year ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/55848

#10 Updated by Gerrit Code Review over 1 year ago

Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/55848

#11 Updated by Gerrit Code Review over 1 year ago

Patch set 8 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/55848

#12 Updated by Gerrit Code Review over 1 year ago

Patch set 9 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/55848

#13 Updated by Gerrit Code Review over 1 year ago

Patch set 10 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/55848

#14 Updated by Gerrit Code Review over 1 year ago

Patch set 1 for branch TYPO3_8-7 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56744

#15 Updated by Gerrit Code Review over 1 year ago

Patch set 2 for branch TYPO3_8-7 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56744

#16 Updated by Ralf Zimmermann over 1 year ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#17 Updated by Benni Mack 11 months ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF