Skip to content
Snippets Groups Projects
Commit a25d54fe authored by Hoi Sing Edison Wong's avatar Hoi Sing Edison Wong Committed by Jakob P
Browse files

Issue #3474908 by japerry, hswong3i: Remove the now defunct menu items for Drupal 11 sites

parent f59fe20d
No related branches found
No related tags found
1 merge request!100Remove the now defunct menu items for Drupal 11 sites
Pipeline #326353 passed with warnings
...@@ -12,7 +12,8 @@ ...@@ -12,7 +12,8 @@
# To test a Drupal 7 project, change the first include filename from .main.yml to .main-d7.yml # To test a Drupal 7 project, change the first include filename from .main.yml to .main-d7.yml
include: include:
- project: $_GITLAB_TEMPLATES_REPO - project: $_GITLAB_TEMPLATES_REPO
ref: $_GITLAB_TEMPLATES_REF # Keep reference on 1.5.10 to support testing against actual current versions of Drupal.
ref: "1.5.10"
file: file:
- "/includes/include.drupalci.main.yml" - "/includes/include.drupalci.main.yml"
- "/includes/include.drupalci.variables.yml" - "/includes/include.drupalci.variables.yml"
......
...@@ -5,10 +5,10 @@ ...@@ -5,10 +5,10 @@
* This is the module to create a drop-down menu for the core toolbar. * This is the module to create a drop-down menu for the core toolbar.
*/ */
use Drupal\admin_toolbar\Render\Element\AdminToolbar;
use Drupal\Component\Utility\Html; use Drupal\Component\Utility\Html;
use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Routing\RouteMatchInterface;
use Drupal\Core\Url; use Drupal\Core\Url;
use Drupal\admin_toolbar\Render\Element\AdminToolbar;
/** /**
* Implements hook_toolbar_alter(). * Implements hook_toolbar_alter().
......
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
namespace Drupal\admin_toolbar_search\Controller; namespace Drupal\admin_toolbar_search\Controller;
use Drupal\admin_toolbar_search\SearchLinks;
use Drupal\Core\Controller\ControllerBase; use Drupal\Core\Controller\ControllerBase;
use Drupal\admin_toolbar_search\SearchLinks;
use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\DependencyInjection\ContainerInterface;
use Symfony\Component\HttpFoundation\JsonResponse; use Symfony\Component\HttpFoundation\JsonResponse;
......
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
namespace Drupal\Tests\admin_toolbar_search\FunctionalJavascript; namespace Drupal\Tests\admin_toolbar_search\FunctionalJavascript;
use Drupal\media\Entity\MediaType;
use Drupal\Tests\media\Traits\MediaTypeCreationTrait; use Drupal\Tests\media\Traits\MediaTypeCreationTrait;
use Drupal\media\Entity\MediaType;
/** /**
* Test the functionality of admin toolbar search. * Test the functionality of admin toolbar search.
......
...@@ -486,21 +486,25 @@ class ExtraLinks extends DeriverBase implements ContainerDeriverInterface { ...@@ -486,21 +486,25 @@ class ExtraLinks extends DeriverBase implements ContainerDeriverInterface {
// If module Update Manager is enabled. // If module Update Manager is enabled.
if ($this->moduleHandler->moduleExists('update')) { if ($this->moduleHandler->moduleExists('update')) {
$links['update.module_install'] = [ if (version_compare(\Drupal::VERSION, '11.0.0', '<')) {
'title' => $this->t('Install new module'), $links['update.module_install'] = [
'route_name' => 'update.module_install', 'title' => $this->t('Install new module'),
'parent' => 'system.modules_list', 'route_name' => 'update.module_install',
] + $base_plugin_definition; 'parent' => 'system.modules_list',
] + $base_plugin_definition;
}
$links['update.module_update'] = [ $links['update.module_update'] = [
'title' => $this->t('Update'), 'title' => $this->t('Update'),
'route_name' => 'update.module_update', 'route_name' => 'update.module_update',
'parent' => 'system.modules_list', 'parent' => 'system.modules_list',
] + $base_plugin_definition; ] + $base_plugin_definition;
$links['update.theme_install'] = [ if (version_compare(\Drupal::VERSION, '11.0.0', '<')) {
'title' => $this->t('Install new theme'), $links['update.theme_install'] = [
'route_name' => 'update.theme_install', 'title' => $this->t('Install new theme'),
'parent' => 'system.themes_page', 'route_name' => 'update.theme_install',
] + $base_plugin_definition; 'parent' => 'system.themes_page',
] + $base_plugin_definition;
}
$links['update.theme_update'] = [ $links['update.theme_update'] = [
'title' => $this->t('Update'), 'title' => $this->t('Update'),
'route_name' => 'update.theme_update', 'route_name' => 'update.theme_update',
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
namespace Drupal\Tests\admin_toolbar\Functional; namespace Drupal\Tests\admin_toolbar\Functional;
use Drupal\Tests\BrowserTestBase;
use Drupal\media\Entity\MediaType; use Drupal\media\Entity\MediaType;
use Drupal\system\Entity\Menu; use Drupal\system\Entity\Menu;
use Drupal\Tests\BrowserTestBase;
/** /**
* Tests Admin Toolbar tools functionality. * Tests Admin Toolbar tools functionality.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment