public function Groups::loadAsOptions in SimpleAds 8
File
- src/
Groups.php, line 113
Class
- Groups
- Groups utility class.
Namespace
Drupal\simpleadsCode
public function loadAsOptions() {
$options = [];
$options[''] = $this
->t('- None -');
foreach ($this
->loadAll() as $item) {
$options[$item
->getId()] = $item
->getGroupName();
}
return $options;
}