public function BooleanCheckboxWidget::settingsSummary in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/lib/Drupal/Core/Field/Plugin/Field/FieldWidget/BooleanCheckboxWidget.php \Drupal\Core\Field\Plugin\Field\FieldWidget\BooleanCheckboxWidget::settingsSummary()
Returns a short summary for the current widget settings.
If an empty result is returned, a UI can still be provided to display a settings form in case the widget has configurable settings.
Return value
array A short summary of the widget settings.
Overrides WidgetBase::settingsSummary
File
- core/
lib/ Drupal/ Core/ Field/ Plugin/ Field/ FieldWidget/ BooleanCheckboxWidget.php, line 53 - Contains \Drupal\Core\Field\Plugin\Field\FieldWidget\BooleanCheckboxWidget.
Class
- BooleanCheckboxWidget
- Plugin implementation of the 'boolean_checkbox' widget.
Namespace
Drupal\Core\Field\Plugin\Field\FieldWidgetCode
public function settingsSummary() {
$summary = array();
$display_label = $this
->getSetting('display_label');
$summary[] = t('Use field label: @display_label', array(
'@display_label' => $display_label ? t('Yes') : 'No',
));
return $summary;
}