You are here

protected function GroupToGroupContent::getContentPluginOptions in Group 8

Same name and namespace in other branches
  1. 2.0.x src/Plugin/views/relationship/GroupToGroupContent.php \Drupal\group\Plugin\views\relationship\GroupToGroupContent::getContentPluginOptions()

Builds the options for the content plugin selection.

Return value

string[] An array of content plugin labels, keyed by plugin ID.

1 call to GroupToGroupContent::getContentPluginOptions()
GroupToGroupContent::buildOptionsForm in src/Plugin/views/relationship/GroupToGroupContent.php
Provide a form to edit options for this plugin.

File

src/Plugin/views/relationship/GroupToGroupContent.php, line 100

Class

GroupToGroupContent
A relationship handler for group content.

Namespace

Drupal\group\Plugin\views\relationship

Code

protected function getContentPluginOptions() {
  $options = [];
  foreach ($this->pluginManager
    ->getAll() as $plugin_id => $plugin) {

    /** @var \Drupal\group\Plugin\GroupContentEnablerInterface $plugin */
    $options[$plugin_id] = $plugin
      ->getLabel();
  }
  return $options;
}