Bug #58520

Epic #62041: twbs Bootstrap backend, refactor EXT:t3skin and HTML5 output

Epic #62836: FormEngine PHP/HTML Improvements & Bootstrap

TCA: selection cannot be removed when size=1, minitems=0, maxitems=1

Added by Christian Weiske over 5 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Should have
Category:
FormEngine aka TCEforms
Target version:
-
Start date:
2014-05-05
Due date:
% Done:

0%

TYPO3 Version:
6.2
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

A TCA select field with size=1, minitems=0 and maxitems=1 always has a selection.
It is not possible to remove it.

As soon as size=2, you get a "x" delete button that allows you to remove the selected item.

2016-09-02 typo3 select size-minitems-maxitems.png View (9.18 KB) Christian Weiske, 2016-09-02 14:23


Related issues

Related to TYPO3 Core - Bug #58521: TCA: select with size=1, maxitems=2 only allows selection of 1 item Closed 2014-05-05
Related to TYPO3 Core - Bug #67913: Flexform: Minitems > 0 within section prevents from saving New 2015-07-06
Related to TYPO3 Core - Bug #76219: select with minitems=1 will not issue an error with no selection Closed 2016-05-18
Related to TYPO3 Core - Bug #77782: Styling glitch when having a select with size=1, minitems=0, maxitems=1 Closed 2016-09-02

History

#1 Updated by Christian Weiske over 5 years ago

That's wrong. As soon as you set maxitems > 1 you get a "delete" button.

#2 Updated by Markus Klein over 5 years ago

  • Status changed from New to Needs Feedback

How do you suggest how this should work in the browser? Should there be an empty option for the select?

#3 Updated by Christian Weiske over 5 years ago

Since it's not possible to have a size=1-select that has no selected option, there are only two options:

1. Make the select size 2 automatically, which allows us to remove the item
2. Automatically add a "no option selected" option that gets special treatment on saving.

Variant 2 is probably the more sensible approach. A "x" button next to the select box could add that option so that it's not visible from the start.

#4 Updated by Markus Klein over 5 years ago

This is going to get a missing feature.
Unfortunately I'm not a specialist on FormEngine, so now clue how to implement that.
I guess it also involves quite some JS magic.

#5 Updated by Felix Kopp almost 5 years ago

  • Parent task set to #62836

#6 Updated by Bodo Eichstädt over 4 years ago

  • Assignee set to Bodo Eichstädt

#7 Updated by Christian Weiske about 4 years ago

Any update?

#8 Updated by Christian Weiske about 3 years ago

This is fixed in TYPO3 7.6.10.

The style is broken (screenshot) because of the min-height of the dropdown, but functionality works.

#9 Updated by Wouter Wolters about 3 years ago

  • Status changed from Needs Feedback to Closed

Created a new issue for the styling issue. https://forge.typo3.org/issues/77782 Closing this one as solved.

Also available in: Atom PDF