function og_get_all_group_content_bundle in Organic groups 7.2
Return all the entities that are a group content.
Return value
Array keyed with the entity type machine name and the entity human readable name as the value, or an empty array if no entities are defined as group content.
1 call to og_get_all_group_content_bundle()
- og_entity_property_info in ./
og.module - Implements hook_entity_property_info().
File
- ./
og.module, line 2564 - Enable users to create and manage groups with roles and permissions.
Code
function og_get_all_group_content_bundle() {
$return = array();
foreach (entity_get_info() as $entity_type => $entity_value) {
foreach ($entity_value['bundles'] as $bundle => $bundle_value) {
if (og_is_group_content_type($entity_type, $bundle)) {
$return[$entity_type][$bundle] = check_plain($bundle_value['label']);
}
}
}
return $return;
}