benjaminkott / benjaminkott/bootstrap_package

FEATURE: using v10 feature #91008 "Item grouping for TCA select items"

Open
#925 1 comment 0 reactions 0 assignees View on GitHub
feature
Dominant language
PHP
Stars
355
Forks
212
Avg merge
1h 4m
Merged PRs (30d)
31

Description

Editing a content element, the select-list for CType is quite messy, because unlike for the newContentElementWizard the content-elements are not grouped here yet.

To implement the new feature [#91008](https://docs.typo3.org/c/typo3/cms-core/master/en-us/Changelog/10.4/Feature-91008-ItemGroupingForTCASelectItems.html#changelog-feature-91008-itemgroupingfortcaselectitems) is quite easy:

Edit `Configuration/TCA/Overrides/102_tt_content.php` to use new API:
```
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTcaSelectItemGroup(
'tt_content',
'CType',
'bootstrap_package',
'LLL:EXT:bootstrap_package/Resources/Private/Language/Backend.xlf:theme_name',
'after:default'
);
```

Edit all content-element TCA definitions to add the group key, e.g. for `200_content_element_accordion.php`:
```
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTcaSelectItem(
'tt_content',
'CType',
[
'LLL:EXT:bootstrap_package/Resources/Private/Language/Backend.xlf:content_element.accordion',
'accordion',
'content-bootstrappackage-accordion',
'bootstrap_package' // add the group item name here as 4th parameter
],
'--div--',
'after'
);
```

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with Configuration/TCA/Overrides/102_tt_content.php and review the content-element TCA definitions, including 200_content_element_accordion.php. Compare the existing definitions with TYPO3's item-group API shown in the issue. Done means the CType select-list content elements are assigned to the bootstrap_package group and display grouped when editing a content element.

Written by the indexing model from the issue text.

Assessment

Tech stack
bootstrap, php
Domain
backend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.