public static function MenuChildrenNodeJoin::create in Views Menu Node Children Filter 3.0.x
Same name and namespace in other branches
- 8.2 src/Plugin/views/join/MenuChildrenNodeJoin.php \Drupal\views_menu_children_filter\Plugin\views\join\MenuChildrenNodeJoin::create()
- 8 src/Plugin/views/join/MenuChildrenNodeJoin.php \Drupal\views_menu_children_filter\Plugin\views\join\MenuChildrenNodeJoin::create()
Creates an instance of the plugin.
Parameters
\Symfony\Component\DependencyInjection\ContainerInterface $container: The container to pull out services used in the plugin.
array $configuration: A configuration array containing information about the plugin instance.
string $plugin_id: The plugin ID for the plugin instance.
mixed $plugin_definition: The plugin implementation definition.
Return value
static Returns an instance of this plugin.
File
- src/
Plugin/ views/ join/ MenuChildrenNodeJoin.php, line 58
Class
- MenuChildrenNodeJoin
- Views Join plugin to join the Node table to the menu_tree table.
Namespace
Drupal\views_menu_children_filter\Plugin\views\joinCode
public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
// Setup some defaults.
$configuration = array_merge(array(
'type' => 'INNER',
'table' => 'menu_link_content_data',
'field' => false,
// Formula value handled in the "buildJoin" function.
'left_table' => false,
'left_field' => false,
'operator' => '=',
), $configuration);
// TODO: Remove this after dev work completed.
// $test = $container->get('views_menu_children_filter.join_handler');
$plugin_id = empty($plugin_id) ? "menu_children_node_join" : $plugin_id;
return new static($container
->get('module_handler'), $configuration, $plugin_id, $plugin_definition);
}