Project

General

Profile

Feature #34098 » groupExcludefields.diff

Joh. Feustel, 2012-02-19 17:25

View differences:

t3lib/class.t3lib_tceforms.php
foreach ($selItems as $p) {
// Non-selectable element:
if (!strcmp($p[1], '--div--')) {
$selIcon = '';
if (isset($p[2]) && $p[2] != 'empty-emtpy') {
$selIcon = $this->getIconHtml($p[2]) ;
}
$tRows[] = '
<tr class="c-header">
<td colspan="3">' . htmlspecialchars($p[0]) . '</td>
<td colspan="3">' . $selIcon . htmlspecialchars($p[0]) . '</td>
</tr>';
} else {
// Selected or not by default:
......
$selIcon = $p[2];
} else {
$selIcon = t3lib_iconWorks::getSpriteIcon('empty-empty');
}
}
// Compile row:
$rowId = uniqid('select_checkbox_row_');
......
switch ($fieldValue['config']['special']) {
case 'tables':
$temp_tc = array_keys($GLOBALS['TCA']);
$descr = '';
foreach ($temp_tc as $theTableNames) {
if (!$GLOBALS['TCA'][$theTableNames]['ctrl']['adminOnly']) {
......
$theTypes = $GLOBALS['TCA']['pages']['columns']['doktype']['config']['items'];
foreach ($theTypes as $theTypeArrays) {
// Icon:
$icon = t3lib_iconWorks::mapRecordTypeToSpriteIconName('pages', array('doktype' => $theTypeArrays[1]));
$icon = 'empty-emtpy';
if ($theTypeArrays[1] != '--div--') {
$icon = t3lib_iconWorks::mapRecordTypeToSpriteIconName(
'pages',
array('doktype' => $theTypeArrays[1])
);
}
// Item configuration:
$items[] = array(
......
break;
case 'exclude':
$theTypes = t3lib_BEfunc::getExcludeFields();
$descr = '';
foreach ($theTypes as $theTypeArrays) {
list($theTable, $theFullField) = explode(':', $theTypeArrays[1]);
......
$theFieldParts = explode(';', $theFullField);
$theField = array_pop($theFieldParts);
// Add header if not yet set for table:
if (!array_key_exists ( $theTable, $items )){
$icon = t3lib_iconWorks::mapRecordTypeToSpriteIconName($theTable, array());
$items[$theTable] = array(
$this->sL($GLOBALS['TCA'][$theTable]['ctrl']['title']),
'--div--',
$icon,
);
}
// Add help text
$helpText = array();
$GLOBALS['LANG']->loadSingleTableDescription($theTable);
......
// Item configuration:
$items[] = array(
rtrim($theTypeArrays[0], ':') . ' (' . $theField . ')',
rtrim($GLOBALS['LANG']->sl($GLOBALS['TCA'][$theTable]['columns'][$theField]['label']), ':') .
' (' . $theField . ')',
$theTypeArrays[1],
'empty-empty',
$helpText
......
$modList = $fieldValue['config']['special'] == 'modListUser' ? $loadModules->modListUser : $loadModules->modListGroup;
if (is_array($modList)) {
$descr = '';
foreach ($modList as $theMod) {
-
(3-3/3)