class ContentDashboard in CMS Content Sync 8
Same name in this branch
- 8 src/Plugin/Derivative/ContentDashboard.php \Drupal\cms_content_sync\Plugin\Derivative\ContentDashboard
- 8 src/Plugin/Menu/ContentDashboard.php \Drupal\cms_content_sync\Plugin\Menu\ContentDashboard
Same name and namespace in other branches
- 2.1.x src/Plugin/Derivative/ContentDashboard.php \Drupal\cms_content_sync\Plugin\Derivative\ContentDashboard
- 2.0.x src/Plugin/Derivative/ContentDashboard.php \Drupal\cms_content_sync\Plugin\Derivative\ContentDashboard
Derivative class that provides the menu links for the Products.
Hierarchy
- class \Drupal\Component\Plugin\Derivative\DeriverBase implements DeriverInterface
- class \Drupal\cms_content_sync\Plugin\Derivative\ContentDashboard implements ContainerDeriverInterface
Expanded class hierarchy of ContentDashboard
1 string reference to 'ContentDashboard'
File
- src/
Plugin/ Derivative/ ContentDashboard.php, line 13
Namespace
Drupal\cms_content_sync\Plugin\DerivativeView source
class ContentDashboard extends DeriverBase implements ContainerDeriverInterface {
/**
* @var \Drupal\Core\Entity\EntityTypeManagerInterface
*/
protected $entityTypeManager;
/**
* Creates a ProductMenuLink instance.
*
* @param $base_plugin_id
*/
public function __construct($base_plugin_id, EntityTypeManagerInterface $entity_type_manager) {
$this->entityTypeManager = $entity_type_manager;
}
/**
* {@inheritdoc}
*/
public static function create(ContainerInterface $container, $base_plugin_id) {
return new static($base_plugin_id, $container
->get('entity_type.manager'));
}
/**
* {@inheritdoc}
*/
public function getDerivativeDefinitions($base_plugin_definition) {
$links = [];
$links['content_dashboard'] = [
'title' => _cms_content_sync_get_repository_name(),
'menu_name' => 'admin',
'parent' => 'system.admin_content',
'route_name' => 'entity.cms_content_sync.content',
] + $base_plugin_definition;
return $links;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ContentDashboard:: |
protected | property | ||
ContentDashboard:: |
public static | function |
Creates a new class instance. Overrides ContainerDeriverInterface:: |
|
ContentDashboard:: |
public | function |
Gets the definition of all derivatives of a base plugin. Overrides DeriverBase:: |
|
ContentDashboard:: |
public | function | Creates a ProductMenuLink instance. | |
DeriverBase:: |
protected | property | List of derivative definitions. | 1 |
DeriverBase:: |
public | function |
Gets the definition of a derivative plugin. Overrides DeriverInterface:: |