Bug #25105 ยป 17672.patch
t3lib/extjs/dataprovider/class.extdirect_dataprovider_contexthelp.php (revision ) | ||
---|---|---|
'moreInfo' => $helpTextArray['moreInfo']
|
||
);
|
||
}
|
||
/**
|
||
* Fetch the context help for the given table
|
||
*
|
||
* @param string $table table identifier
|
||
* @return array complete help information
|
||
*/
|
||
public function getTableContextHelp($table) {
|
||
$output = array();
|
||
if (!isset($GLOBALS['TCA_DESCR'][$table]['columns'])) {
|
||
$GLOBALS['LANG']->loadSingleTableDescription($table);
|
||
}
|
||
}
|
||
if (is_array($GLOBALS['TCA_DESCR'][$table]) && is_array($GLOBALS['TCA_DESCR'][$table]['columns'])) {
|
||
foreach ($GLOBALS['TCA_DESCR'][$table]['columns'] as $field => $data) {
|
||
$output[$field] = array(
|
||
'description' => NULL,
|
||
'title' => NULL,
|
||
'moreInfo' => FALSE,
|
||
'id' => $table . '.' . $field,
|
||
);
|
||
// add alternative title, if defined
|
||
if ($data['alttitle']) {
|
||
$output[$field]['title'] = $data['alttitle'];
|
||
}
|
||
// if we have more information to show
|
||
if ($data['image_descr'] || $data['seeAlso'] || $data['details'] || $data['syntax']) {
|
||
$output[$field]['moreInfo'] = TRUE;
|
||
}
|
||
// add description
|
||
if ($data['description']) {
|
||
$output[$field]['description'] = $data['description'];
|
||
}
|
||
}
|
||
}
|
||
return $output;
|
||
}
|
||
}
|
||
?>
|
t3lib/js/extjs/contexthelp.js (revision ) | ||
---|---|---|
title: ''
|
||
});
|
||
// Load content
|
||
TYPO3.CSH.ExtDirect.getContextHelp(table, field, function(response, options) {
|
||
cshHelp.add(response);
|
||
updateTip(response);
|
||
TYPO3.CSH.ExtDirect.getTableContextHelp(table, function(response, options) {
|
||
Ext.iterate(response, function(key, value){
|
||
cshHelp.add(value);
|
||
if (key === field) {
|
||
updateTip(value);
|
||
// Need to re-position because the height may have increased
|
||
tip.show();
|
||
// Need to re-position because the height may have increased
|
||
tip.show();
|
||
}
|
||
});
|
||
}, this);
|
||
// No table was given, use directly title and description
|