public function SettingTrait::getHumanReadableValueList in Fasttoggle 8.2
Get a plain text list of human readable labels for the setting, in the order used.
This allows human readable labels to be sorted in non-alphabetical order. Note that the widget object may use this or an attribute of the value itself to render an icon, an ajax link or something else.
Return value
array An array of human readable values, in the order they will appear when stepping through them.
File
- src/
Plugin/ Setting/ SettingTrait.php, line 251 - Fasttoggle Object List of Values Setting
Class
- SettingTrait
- Abstract interface for settings.
Namespace
Drupal\fasttoggle\Plugin\SettingCode
public function getHumanReadableValueList() {
$labels = $this->labels;
$config = $this
->config('fasttoggle.settings');
$label_type = $config
->get('label_type');
return $labels[$label_type];
}