You are here

public static function RulesDataUIOrganigrams::optionsList in Organigrams 7

Implements RulesDataInputOptionsListInterface::optionsList().

Parameters

\RulesPlugin $element: Contains a rules plugin.

string $name: Contains an Organigrams name.

Return value

array Array containing organigram names.

Overrides RulesDataInputOptionsListInterface::optionsList

File

./organigrams.rules.inc, line 247
Rules integration for the organigrams module.

Class

RulesDataUIOrganigrams
UI for taxonomy vocabularies.

Code

public static function optionsList(RulesPlugin $element, $name) {
  $options = array();
  foreach (organigrams_get_names() as $machine_name => $organigram) {
    $options[$machine_name] = $organigram->name;
  }
  return $options;
}