Open patrickklosedev opened 4 months ago
TYPO3 12? "Layout-Mode" but "Language-Comparison-Mode"
this is same as core backend_layout rendering behaviour.
Yes, Typo3 V12. And even in Layout Mode, it doesn't work.
When I check the source code, the defined colspan is not used. By changing this value directly in the source code, it works (temporary):
this is my source-code (with EXT:container_example, https://github.com/b13/container-example/blob/master/Configuration/TCA/Overrides/tt_content.php#L11) ah i see ..., you have to write "colspan" instead of "colSpan" in your configuration
Unfortunately, this doesn't work either... I already have this tried before.
I will try out your code example and get back to you.
Same issue in v12.
Same problem here with TYPO3 11 and latest EXT:container. PHP 7.4 or 8.2 doesn't matter.
It works in column view, but not in language view.
Typo3 12.4.21 PHP 8.2 Container 2.3.6
\TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\B13\Container\Tca\Registry::class)->configureContainer( ( new \B13\Container\Tca\ContainerConfiguration( '2cols-container', // CType '2 Spalten', // label 'Container Element für 2 Spalten', // description [ [ ['name' => 'linke Spalte', 'colPos' => 10], ['name' => 'rechte Spalte', 'colPos' => 20], ], [ ['name' => 'Erweiterung', 'colPos' => 30, 'colspan' => 2] ] ] // grid configuration )
We have examined the problem in detail. The reason why the colspan set in the TCA is not used could be found in sysext/backend/Classes/View/BackendLayout/Grid/GridColumn.php:
public function getColSpan(): int
{
if ($this->context->getDrawingConfiguration()->getLanguageMode()) {
return 1;
}
return $this->colSpan;
}
In languageView the TCA values are ignored. Crazy...
Thanks for digging into it. So next step is to open a core issue?
I have the following configuration in the file tt_content.php:
According to an example of this extension, this should lead to having the first row span the two columns that follow. However, this is the result in the backend:
Is this a bug or did I used "colSpan" wrongly?