[TYPO3-core] RFC #17024: Bug: CSH not rendered properly in select-type fields with renderMode = checkbox
François Suter
fsu-lists at cobweb.ch
Thu Jan 20 22:48:46 CET 2011
This is an SVN patch request.
Type: Bugfix
Bugtracker references:
http://bugs.typo3.org/view.php?id=17024
Branches:
Trunk
Problem:
When a select-type field is rendered as checkboxes (e.g. the access
lists in the be_groups), the CSH is not rendered properly.
Solution:
Use the new API. To achieve this it was necessary to modify a bit said
API (see note 1). And of course t3lib_TCEforms had to be adapted
accordingly. I encountered just a minor problem (see note 3) and made a
very small unrelated cleanup (see note 2).
Notes:
1) In order to make this possible, an additional parameter was added to
t3lib_BEfunc::wrapInHelp() which makes it possible to directly pass a
title and a description and bypass the whole TCA_DESCR business. This
title and description are added as attributes to the <span> tag
representing the help. They are used straightaway by the contexthelp JS
without ExtDirect calls (thanks to Steffen Kamper for the proof of
concept) when the table (in attribute "data-table") is empty. Hence the
call in t3lib_TCEforms:
$help = t3lib_BEfunc::wrapInHelp('', '', '', $helpArray);
with the many empty parameters.
2) You may notice a change not directly related to this patch in
t3lib_BEfunc::wrapInHelp(). I have removed the early call to
$GLOBALS['LANG']->loadSingleTableDescription($table), because
t3lib_BEfunc::helpText() is called right after that, which in turn calls
t3lib_BEfunc::helpTextArray() which calls finally
$GLOBALS['LANG']->loadSingleTableDescription($table). So we had a
redundancy.
3) There's a problem with the rendering of the tooltips in the list of
"Allowed excludefields" in be_groups. The "tip" of the tooltip is
rendered above the bubble, at least on FF for Mac. Since the attached
patch only calls the proper API, I guess it's an issue that must be
solved separately, once this RFC has been committed.
4) A minor note: for custom select-type fields, there's only a
description and no title. I quickly checked if support for a title could
be added, but there's already another property used after the
description, so I thought it would be messy to add the title somewhere
further. Anyway people have lived without it until now ;-)
Cheers
--
Francois Suter
Cobweb Development Sarl - http://www.cobweb.ch
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 17024.diff
URL: <http://lists.typo3.org/pipermail/typo3-team-core/attachments/20110120/7d865d6d/attachment-0001.asc>
More information about the TYPO3-team-core
mailing list