diff --git modules/system/system.admin.inc modules/system/system.admin.inc
index 1e7dad0..a2fbc37 100644
--- modules/system/system.admin.inc
+++ modules/system/system.admin.inc
@@ -2078,6 +2078,8 @@ function theme_status_report($requirements) {
* @ingroup themeable
*/
function theme_system_modules_fieldset($form) {
+ drupal_add_js(drupal_get_path('module', 'system') . '/system_modules.js', array('weight' => JS_THEME));
+
// Individual table headers.
$rows = array();
// Iterate through all the modules, which are
@@ -2103,9 +2105,11 @@ function theme_system_modules_fieldset($form) {
// Add the description, along with any modules it requires.
$description .= drupal_render($module['description']);
if ($module['#relationships']) {
+ $description .= '
';
foreach ($module['#relationships'] as $relationship) {
- $description .= '
' . $relationship['name'] . ': ' . implode(', ', $relationship['values']) . '
';
+ $description .= '
' . $relationship['name'] . ': ' . implode(', ', $relationship['values']) . '
';
}
+ $description .= '
';
}
$row[] = array('data' => $description, 'class' => 'description');
$rows[] = $row;
diff --git modules/system/system_modules.js modules/system/system_modules.js
new file mode 100644
index 0000000..5e1b7ba
--- /dev/null
+++ modules/system/system_modules.js
@@ -0,0 +1,34 @@
+(function ($) {
+
+Drupal.behaviors.systemModuleRelationship = {
+ attach: function (context) {
+ $('.admin-requirements', context).each(function () {
+ var req, summary;
+ req = $(this);
+ summary = $('');
+ req.children('div').each(function () {
+ var $this, name, count, currentText, newText;
+ $this = $(this);
+ name = $this.find('.admin-relationship').text();
+ count = $this.find('.admin-related-modules').text().split(',').length;
+ newText = name + ' ' + count;
+ currentText = summary.text();
+ if (currentText) {
+ currentText += ', ';
+ }
+ summary.text(currentText + newText);
+ });
+ req.hide().click(function () {
+ summary.show();
+ req.hide();
+ });
+ summary.insertBefore(req).attr('href', '#').wrap($('').addClass('admin-requirements admin-requirements-summary')).click(function () {
+ summary.hide();
+ req.show();
+ return false;
+ });
+ });
+ }
+};
+
+})(jQuery);
\ No newline at end of file