diff --git a/core/modules/config/src/Tests/ConfigImportAllTest.php b/core/modules/config/src/Tests/ConfigImportAllTest.php index baeacb9..004c5b5 100644 --- a/core/modules/config/src/Tests/ConfigImportAllTest.php +++ b/core/modules/config/src/Tests/ConfigImportAllTest.php @@ -7,6 +7,7 @@ use Drupal\system\Tests\Module\ModuleTestBase; use Drupal\shortcut\Entity\Shortcut; use Drupal\taxonomy\Entity\Term; +use Drupal\workspace\Entity\Workspace; /** * Tests the largest configuration import possible with all available modules. @@ -92,6 +93,10 @@ public function testInstallUninstall() { $shortcuts = Shortcut::loadMultiple(); entity_delete_multiple('shortcut', array_keys($shortcuts)); + // Delete any workspaces so the workspace module can be uninstalled. + $workspaces = Workspace::loadMultiple(); + \Drupal::entityTypeManager()->getStorage('workspace')->delete($workspaces); + system_list_reset(); $all_modules = system_rebuild_module_data(); diff --git a/core/modules/workspace/templates/workspace-add-list.html.twig b/core/modules/workspace/templates/workspace-add-list.html.twig index 29ec74b..6a0ff29 100644 --- a/core/modules/workspace/templates/workspace-add-list.html.twig +++ b/core/modules/workspace/templates/workspace-add-list.html.twig @@ -8,8 +8,6 @@ * Each Workspace type contains the following: * - link: A link to add a Workspace of this type. * - * @see template_preprocess_block_content_add_list() - * * @ingroup themeable */ #} diff --git a/core/modules/workspace/workspace.info.yml b/core/modules/workspace/workspace.info.yml index e01c064..27e086e 100644 --- a/core/modules/workspace/workspace.info.yml +++ b/core/modules/workspace/workspace.info.yml @@ -1,4 +1,8 @@ name: Workspace type: module -description: Provides the ability to have multiple workspaces on a single site to facilitate things like full-site preview and content staging. +description: 'Provides the ability to have multiple workspaces on a single site to facilitate things like full-site preview and content staging.' +version: VERSION core: 8.x +package: Core (Experimental) +dependencies: + - user diff --git a/core/modules/workspace/workspace.module b/core/modules/workspace/workspace.module index 91b63e1..bd387e2 100644 --- a/core/modules/workspace/workspace.module +++ b/core/modules/workspace/workspace.module @@ -5,12 +5,27 @@ use Drupal\Core\Entity\EntityTypeInterface; use Drupal\Core\Field\BaseFieldDefinition; use Drupal\Core\Link; +use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Session\AccountInterface; use Drupal\Core\Url; use Drupal\workspace\Entity\WorkspaceInterface; use Drupal\workspace\Plugin\Field\WorkspaceFieldItemList; /** + * Implements hook_help(). + */ +function workspace_help($route_name, RouteMatchInterface $route_match) { + switch ($route_name) { + // Main module help for the workspace module. + case 'help.page.workspace': + $output = ''; + $output .= '

' . t('About') . '

'; + $output .= '

' . t('The Workspace module allows workspaces to be defined and switched between. Content is then assigned to the active workspace when created. For more information, see the online documentation for the Workspace module.', [':workspace' => 'https://www.drupal.org/node/2824024']) . '

'; + return $output; + } +} + +/** * Implements hook_entity_base_field_info(). */ function workspace_entity_base_field_info(EntityTypeInterface $entity_type) {