function command_buttons_get_bundle_labels in Command Buttons 7
Get an array of entity bundle names, suitable for an options form.
1 call to command_buttons_get_bundle_labels()
- command_buttons_handler_filter_bundle::get_value_options in plugins/
views/ command_buttons_handler_filter_bundle.inc - Child classes should be used to override this function and set the 'value options', unless 'options callback' is defined as a valid function or static public method to generate these values.
File
- ./
command_buttons.module, line 487
Code
function command_buttons_get_bundle_labels() {
$bundles = array();
$entity_info = entity_get_info('command_button');
foreach ($entity_info['bundles'] as $bundle => $info) {
$bundles[$bundle] = $info['label'];
}
asort($bundles);
return $bundles;
}