/** * Injects the content designer explicit allow/deny configuration. * * @param array $result * @return array */ public function addData(array $result) { // Only if editing the be_groups table if ($result['tableName'] != 'be_groups' && is_array($result['processedTca']['columns']['explicit_allowdeny']['config']['items'])) { return $result; } // Preconf $table = 'tt_content'; $explicitADMode = $GLOBALS['TYPO3_CONF_VARS']['BE']['explicitADmode'] == 'explicitAllow' ? 'ALLOW' : 'DENY'; $adModeLang = array('ALLOW' => $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:labels.allow'), 'DENY' => $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:labels.deny')); $icons = array('ALLOW' => 'status-status-permission-granted', 'DENY' => 'status-status-permission-denied'); // Load TS Setup Content Designer Items $contentDesignerItems = TypoScript::getFromAnywhere($table . '.', 'tx_contentdesigner_', TRUE); // Merge the content designer items to the explicitAllowDeny selector if (sizeof($contentDesignerItems) > 0) { $items =& $result['processedTca']['columns']['explicit_allowdeny']['config']['items']; // Add divider $items[] = array('Content Designer:', '--div--', NULL, NULL); // Add items foreach ($contentDesignerItems as $itemKey => $itemConf) { $itemSettings =& $itemConf['settings.']; // Put into result $items[] = array('[' . $adModeLang[$explicitADMode] . '] ' . $GLOBALS['LANG']->sL($itemSettings['title']), $table . ':CType:' . $itemKey . ':' . $explicitADMode, $icons[$explicitADMode], NULL); } } return $result; }