public function SwitchField::isAllowed in Display Suite 8.4
Same name and namespace in other branches
- 8.2 modules/ds_extras/src/Plugin/DsField/SwitchField.php \Drupal\ds_extras\Plugin\DsField\SwitchField::isAllowed()
- 8.3 modules/ds_extras/src/Plugin/DsField/SwitchField.php \Drupal\ds_extras\Plugin\DsField\SwitchField::isAllowed()
Returns if the field is allowed on the field UI screen.
Return value
bool TRUE when field allowed, FALSE otherwise.
Overrides DsFieldBase::isAllowed
File
- modules/
ds_extras/ src/ Plugin/ DsField/ SwitchField.php, line 181
Class
- SwitchField
- Plugin that generates a link to switch view mode with via ajax.
Namespace
Drupal\ds_extras\Plugin\DsFieldCode
public function isAllowed() {
if (\Drupal::config('ds_extras.settings')
->get('switch_field')) {
return TRUE;
}
return FALSE;
}