Project

General

Profile

Actions

Bug #40656

closed

t3lib_TCEforms_inline->createNewRecord doesn't create localized records

Added by Viktor Livakivskyi over 11 years ago. Updated over 6 years ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
FormEngine aka TCEforms
Target version:
Start date:
2012-09-05
Due date:
% Done:

0%

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

Description

Hi.

Today we've found an issue in createNewRecord method of t3lib_TCEforms_inline class.
Line 1106 contains such a condition:
if ($config['localizationMode'] == 'select')
But TCA specification (http://typo3.org/documentation/document-library/core-documentation/doc_core_tca/4.7.1/view/1/3/#id590095) says, that localizationMode is part of 'behaviour' config setting, so, when someone tries to create a new 'inline' record inside of localized parent record, 'inline' record get olways created with sys_language_uid=0, because condition above will never be TRUE.
Current hack is to make specification in such a way:

'field_name' => array (
    'label' => 'field',
    'config' => array (
        'type' => 'inline',
        'foreign_table' => 'tx_inline_records',
        'foreign_field' => 'parent_id',
        'behaviour' => array(
            'localizationMode' => 'select'
        ),
        'localizationMode' => 'select',
    )
),

localizationMode must be set two times: on root of 'config' and inside of 'behaviour'.

Fix:
Line 1106:
if ($config['behaviour']['localizationMode'] == 'select')

TYPO3 4.7.4


Related issues 3 (0 open3 closed)

Related to TYPO3 Core - Bug #21964: New child records created from a translated record have default languageClosed2010-01-15

Actions
Related to TYPO3 Core - Bug #57272: Extbase doesn't handle FAL translations correctlyClosed2014-03-25

Actions
Related to TYPO3 Core - Bug #57063: Parent language is not applied to new child recordsClosed2014-03-19

Actions
Actions

Also available in: Atom PDF