Bug #21453 ยป bug12464.diff
typo3/sysext/reports/reports/class.tx_reports_reports_status.php (working copy) | ||
---|---|---|
$content = '';
|
||
foreach ($this->statusProviders as $statusProviderId => $statusProvider) {
|
||
if (strcmp(substr($statusProviderId, 0, 4), 'LLL:')) {
|
||
$providerLabel = $GLOBALS['LANG']->getLL('status_' . $statusProviderId);
|
||
} else {
|
||
// label from extension
|
||
$providerLabel = $GLOBALS['LANG']->sL($statusProviderId);
|
||
}
|
||
$provider = $providerLabel ? $providerLabel : $statusProviderId;
|
||
$status[$provider] = $statusProvider->getStatus();
|
||
$status[$statusProviderId] = $statusProvider->getStatus();
|
||
}
|
||
$content .= '<p class="help">'
|
||
... | ... | |
}
|
||
/**
|
||
* sorts the status providers (alphabetically and adds "_install" provider at the beginning)
|
||
* Sorts the status providers (alphabetically and puts primary status providers at the beginning)
|
||
*
|
||
* @param array A collection of statuses (with providers)
|
||
* @return array The collection of statuses sorted by provider (beginning with provider "_install")
|
||
*/
|
||
protected function sortStatusProviders(array $statusCollection) {
|
||
$systemStatus = array(
|
||
'TYPO3 System' => $statusCollection['Installation'],
|
||
'System' => $statusCollection['System'],
|
||
'Security' => $statusCollection['security'],
|
||
'Configuration' => $statusCollection['configuration'],
|
||
// Extract the primary status collections, i.e. the status groups
|
||
// that must appear on top of the status report
|
||
// Change their keys to localized collection titles
|
||
$primaryStatuses = array(
|
||
$GLOBALS['LANG']->getLL('status_typo3') => $statusCollection['typo3'],
|
||
$GLOBALS['LANG']->getLL('status_system') => $statusCollection['system'],
|
||
$GLOBALS['LANG']->getLL('status_security') => $statusCollection['security'],
|
||
$GLOBALS['LANG']->getLL('status_configuration') => $statusCollection['configuration']
|
||
);
|
||
unset(
|
||
$statusCollection['Installation'],
|
||
$statusCollection['System'],
|
||
$statusCollection['typo3'],
|
||
$statusCollection['system'],
|
||
$statusCollection['security'],
|
||
$statusCollection['configuration']
|
||
);
|
||
ksort($statusCollection);
|
||
$statusCollection = array_merge($systemStatus, $statusCollection);
|
||
// Assemble list of secondary status collections with left-over collections
|
||
// Change their keys using localized labels if available
|
||
$secondaryStatuses = array();
|
||
foreach ($statusCollection as $statusProviderId => $collection) {
|
||
$label = '';
|
||
if (strpos($statusProviderId, 'LLL:') === 0) {
|
||
// Label provided by extension
|
||
$label = $GLOBALS['LANG']->sL($statusProviderId);
|
||
} else {
|
||
// Generic label
|
||
$label = $GLOBALS['LANG']->getLL('status_' . $statusProviderId);
|
||
}
|
||
$providerLabel = (empty($label)) ? $statusProviderId : $label;
|
||
$secondaryStatuses[$providerLabel] = $collection;
|
||
}
|
||
// Sort the secondary status collections alphabetically
|
||
ksort($secondaryStatuses);
|
||
$orderedStatusCollection = array_merge($primaryStatuses, $secondaryStatuses);
|
||
return $statusCollection;
|
||
return $orderedStatusCollection;
|
||
}
|
||
/**
|
typo3/sysext/reports/reports/locallang.xml (working copy) | ||
---|---|---|
<label index="status_connectionFailed">Connection Failed</label>
|
||
<label index="status_updateComplete">Update Complete</label>
|
||
<label index="status_updateIncomplete">Update Incomplete</label>
|
||
<label index="status__install">Installation</label>
|
||
<label index="status_typo3">TYPO3 System</label>
|
||
<label index="status_system">System</label>
|
||
<label index="status_security">Security</label>
|
||
<label index="status_configuration">Configuration</label>
|
||
</languageKey>
|
||
</data>
|
||
</T3locallang>
|
typo3/sysext/install/ext_tables.php (working copy) | ||
---|---|---|
if (TYPO3_MODE=='BE') {
|
||
t3lib_extMgm::addModule('tools', 'install', '', t3lib_extMgm::extPath($_EXTKEY) . 'mod/');
|
||
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['reports']['tx_reports']['status']['providers']['_install'] = 'tx_install_report_InstallStatus';
|
||
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['reports']['tx_reports']['status']['providers']['typo3'] = 'tx_install_report_InstallStatus';
|
||
}
|
||
?>
|