Project

General

Profile

Actions

Bug #71239

open

FAL relation + flexform config: Use full setting path as name

Added by Christian Weiske over 8 years ago. Updated about 5 years ago.

Status:
New
Priority:
Should have
Assignee:
-
Category:
FormEngine aka TCEforms
Target version:
-
Start date:
2015-11-02
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

Multiple FAL relations in a single flexform do not work if the fields have the same name, but different path (through nesting).

This leads to bugs like
- fluidpages #285: Page configuration: <flux:field.inline.fal> value duplicated for subpage config
- flux #759: inline.fal in a form.container

@Claus Due described the problem as follows:

The situation is that the FAL relation field types were initially created for purely record relations, and the support for using the same field in a FlexForm context is more of an afterthought; an adaptation that allows the field to store at least basic relations when used in a FlexForm.

Technically, the issue is that when you save a record that has a FlexForm with a FAL field, the FAL relation is stored using the field name without considering the nesting which means that all your relations have the field name image after they're saved. Of course, when you reload the form, the methods that pre-fill the FAL relation fields are then detecting the same relation in all fields.

The solution would be to parse the nesting structure of the FlexForm when determining which field name to use when the relation is stored in the database. This would allow TYPO3 to store a field name like settings.foreground.image in your case, rather than simply image. If the method that renders the field is then also capable of determining the same (I believe this needs to be added) the puzzle should be solved, allowing any combination of nested FAL/IRRE fields inside and outside FlexForms in the same way.

Actions

Also available in: Atom PDF