Project

General

Profile

Actions

Bug #98323

closed

auto creation of table isn't done if options never fit exact needs

Added by David Bruchmann over 1 year ago. Updated over 1 year ago.

Status:
Rejected
Priority:
Should have
Assignee:
-
Category:
-
Target version:
Start date:
2022-09-10
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
12
PHP Version:
8.1
Tags:
tca table-auto-creation
Complexity:
Is Regression:
Sprint Focus:

Description

Having a configuration like this:


        'related_posts' => [
            'exclude' => true,
            'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xlf:tx_blogexample_domain_model_post.related',
            'config' => [
                'type' => 'select',
                'renderType' => 'selectMultipleSideBySide',
                'size' => 10,
                'autoSizeMax' => 30,
                'multiple' => 0,
                'foreign_table' => 'tx_blogexample_domain_model_post',
                'foreign_table_where' => 'AND ###THIS_UID### != tx_blogexample_domain_model_post.uid',
                'MM' => 'tx_blogexample_post_post_mm',
                'MM_opposite_field' => 'related_posts',
            ],
        ],

the table isn't created.
The culprit here is the option 'MM_opposite_field', removing it, it works like expected.

Actions #1

Updated by Benni Mack over 1 year ago

  • Target version changed from 12.0 to 12.1
Actions #2

Updated by Christian Kuhn over 1 year ago

  • Status changed from New to Rejected

Hey.

That's intended: MM table auto generation is always only created when looking at it from the "local" / "left" TCA table. With MM_opposite_field you specify you're on the "foreign" / "right" side. That's basically because there can be more than one "foreign" tables, so the DefaultTcaSchema always looks at MM from the "local" side only, to not mix up things.

Actions

Also available in: Atom PDF