Bug #45125
closedHide "Create new relation" for FAL fields, if maxitems = 1 and an image is selected
100%
Description
It would be a better useability, if the link "Create new relation" hide, when an image is selected and only one image is allowed.
I have the following code in my TCA definition:
'image' => array(
'exclude' => 1,
'label' => 'LLL:EXT:my_extkey/Resources/Private/Language/locallang_db.xlf:tx_myextkey_domain_model_tablename.image',
'config' => \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getFileFieldTCAConfig('media', array('maxitems' => 1))
),
Updated by Andreas Wolf almost 12 years ago
- Status changed from New to Accepted
I think this is a general problem with IRRE and should be tackled when cleaning up the backend Javascript code. Maybe it's also possible to do it right now - do you know Javascript and could dive into this? I'd also try to help if you get stuck somewhere.
Updated by Andreas Kießling almost 12 years ago
I'd prefer a solution like it is for group fields since (i think) 4.6: if max 1 element is allowed, the existing relation should be replaced. No need to first delete it. For group fields, the visual indicator is simply the height of the selector box. I'm not sure how this could be implemented for the FAL fields, since there is just the link to add a relation.
Maybe adjusting the label is then enough, to tell a user that only one image / element is possible here?
Updated by Andreas Kießling about 10 years ago
Any news on how to proceed here? I'd really like a solution for 6.2, even if the label just tells "You can't add any more files"
Updated by Frans Saris about 10 years ago
Hi see #61031 there is a patch pending that introduces a message when max items is reached.
Updated by Jan Helke over 9 years ago
- Assignee set to Jan Helke
- Target version changed from 6.0.2 to 7.3 (Packages)
- PHP Version changed from 5.3 to 5.5
The code in typo3/sysext/backend/Classes/Form/Container/InlineControlContainer.php indicates, that the behavior Tobias wants is in fact indented by the core. As I stumbled upon this too, I can provide a patch for that.
Updated by Jan Helke over 9 years ago
- Tracker changed from Feature to Bug
- TYPO3 Version set to 7
- Complexity set to medium
- Is Regression set to No
Updated by Gerrit Code Review over 9 years ago
- Status changed from Accepted to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40157
Updated by Benni Mack over 9 years ago
- Target version changed from 7.3 (Packages) to 7.4 (Backend)
Updated by Gerrit Code Review over 9 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40157
Updated by Gerrit Code Review over 9 years ago
Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40157
Updated by Gerrit Code Review over 9 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40257
Updated by Gerrit Code Review over 9 years ago
Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40257
Updated by Gerrit Code Review over 9 years ago
Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40257
Updated by Gerrit Code Review over 9 years ago
Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40257
Updated by Gerrit Code Review over 9 years ago
Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40257
Updated by Jonathan IROULIN over 9 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 9d83190cd607d653947303b35523bc7ef0d24e4e.
Updated by Riccardo De Contardi about 7 years ago
- Status changed from Resolved to Closed