protected function ConditionalFieldForm::getFieldsList in Conditional Fields 4.x
Same name and namespace in other branches
- 8 src/Form/ConditionalFieldForm.php \Drupal\conditional_fields\Form\ConditionalFieldForm::getFieldsList()
Build options list of available fields.
1 call to ConditionalFieldForm::getFieldsList()
- ConditionalFieldForm::buildTable in src/
Form/ ConditionalFieldForm.php - Builds table with conditional fields.
File
- src/
Form/ ConditionalFieldForm.php, line 433
Class
- ConditionalFieldForm
- A form with a list of conditional fields for an entity type.
Namespace
Drupal\conditional_fields\FormCode
protected function getFieldsList() {
$dependency_helper = new DependencyHelper($this->entity_type, $this->bundle_name);
$fields = [];
foreach ($dependency_helper
->getAvailableConditionalFields() as $name => $label) {
$fields[$name] = $label . ' (' . $name . ')';
}
return $fields;
}