comparison core/modules/system/src/Controller/SystemController.php @ 17:129ea1e6d783

Update, including to Drupal core 8.6.10
author Chris Cannam
date Thu, 28 Feb 2019 13:21:36 +0000
parents 4c8ae668cc8c
children
comparison
equal deleted inserted replaced
16:c2387f117808 17:129ea1e6d783
98 * A renderable array of the administration overview page. 98 * A renderable array of the administration overview page.
99 */ 99 */
100 public function overview($link_id) { 100 public function overview($link_id) {
101 // Check for status report errors. 101 // Check for status report errors.
102 if ($this->systemManager->checkRequirements() && $this->currentUser()->hasPermission('administer site configuration')) { 102 if ($this->systemManager->checkRequirements() && $this->currentUser()->hasPermission('administer site configuration')) {
103 drupal_set_message($this->t('One or more problems were detected with your Drupal installation. Check the <a href=":status">status report</a> for more information.', [':status' => $this->url('system.status')]), 'error'); 103 $this->messenger()->addError($this->t('One or more problems were detected with your Drupal installation. Check the <a href=":status">status report</a> for more information.', [':status' => $this->url('system.status')]));
104 } 104 }
105 // Load all menu links below it. 105 // Load all menu links below it.
106 $parameters = new MenuTreeParameters(); 106 $parameters = new MenuTreeParameters();
107 $parameters->setRoot($link_id)->excludeRoot()->setTopLevelOnly()->onlyEnabledLinks(); 107 $parameters->setRoot($link_id)->excludeRoot()->setTopLevelOnly()->onlyEnabledLinks();
108 $tree = $this->menuLinkTree->load(NULL, $parameters); 108 $tree = $this->menuLinkTree->load(NULL, $parameters);
185 // Get all available themes. 185 // Get all available themes.
186 $themes = $this->themeHandler->rebuildThemeData(); 186 $themes = $this->themeHandler->rebuildThemeData();
187 uasort($themes, 'system_sort_modules_by_info_name'); 187 uasort($themes, 'system_sort_modules_by_info_name');
188 188
189 $theme_default = $config->get('default'); 189 $theme_default = $config->get('default');
190 $theme_groups = ['installed' => [], 'uninstalled' => []]; 190 $theme_groups = ['installed' => [], 'uninstalled' => []];
191 $admin_theme = $config->get('admin'); 191 $admin_theme = $config->get('admin');
192 $admin_theme_options = []; 192 $admin_theme_options = [];
193 193
194 foreach ($themes as &$theme) { 194 foreach ($themes as &$theme) {
195 if (!empty($theme->info['hidden'])) { 195 if (!empty($theme->info['hidden'])) {