You are here

function fieldable_panels_panes_get_bundle_label in Fieldable Panels Panes (FPP) 7

Get the safe human readable name of an entity bundle.

5 calls to fieldable_panels_panes_get_bundle_label()
fieldable_panels_panes_entity_delete_form_submit in includes/admin.inc
Execute node deletion.
fieldable_panels_panes_handler_argument_bundle::summary_name in plugins/views/fieldable_panels_panes_handler_argument_bundle.inc
Provides the name to use for the summary.
fieldable_panels_panes_handler_argument_bundle::title in plugins/views/fieldable_panels_panes_handler_argument_bundle.inc
Get the title this argument will assign the view, given the argument.
fieldable_panels_panes_handler_field_bundle::render in plugins/views/fieldable_panels_panes_handler_field_bundle.inc
Render the field.
FppPermissionsTest::testDeleteBundlePermission in tests/fpp.permissions.test
Confirm that the 'delete bundle' permission works correctly.

File

./fieldable_panels_panes.module, line 1178
Maintains an entity that appears as panel pane content.

Code

function fieldable_panels_panes_get_bundle_label($bundle) {
  $entity_info = entity_get_info('fieldable_panels_pane');
  if (empty($entity_info['bundles'][$bundle]['label'])) {
    $output = t('Unknown content type');
  }
  return $entity_info['bundles'][$bundle]['label'];
}