public function Pattern::alterForm in UI Patterns 8
File
- modules/
ui_patterns_ds/ src/ Plugin/ DsFieldTemplate/ Pattern.php, line 111
Class
- Pattern
- Plugin for the expert field template.
Namespace
Drupal\ui_patterns_ds\Plugin\DsFieldTemplateCode
public function alterForm(&$form) {
$context = $this
->getContext();
if ($this
->isSupportedField($context)) {
$this
->buildPatternDisplayForm($form, 'ds_field_template', $context, $this
->getConfiguration());
}
else {
$form['#markup'] = $this
->t("The current field is not supported.");
}
}