You are here

function _crm_core_relationships_ui_breadcrmub in CRM Core 7

Same name and namespace in other branches
  1. 8.3 modules/crm_core_relationship_ui/crm_core_relationship_ui.module \_crm_core_relationships_ui_breadcrmub()
  2. 8 modules/crm_core_relationship_ui/crm_core_relationship_ui.module \_crm_core_relationships_ui_breadcrmub()
  3. 8.2 modules/crm_core_relationship_ui/crm_core_relationship_ui.module \_crm_core_relationships_ui_breadcrmub()

Helper function sets breadcrumb on contact pages.

Parameters

$contact object: Entity object of crm_core_contact type.

2 calls to _crm_core_relationships_ui_breadcrmub()
crm_core_relationship_ui_add_relationship in modules/crm_core_relationship_ui/crm_core_relationship_ui.pages.inc
Return a list of links to add relationship for specific CRM contact.
crm_core_relationship_ui_views_pre_render in modules/crm_core_relationship_ui/crm_core_relationship_ui.module
Implements hook_views_pre_render().

File

modules/crm_core_relationship_ui/crm_core_relationship_ui.module, line 364

Code

function _crm_core_relationships_ui_breadcrmub($contact) {
  $contact_uri = $contact
    ->uri();
  $breadcrumb = array(
    l(t('Home'), '<front>'),
    l(t('CRM Core'), 'crm-core'),
    l(t('Contacts'), 'crm-core/contact'),
    l(t($contact
      ->label()), $contact_uri['path']),
    l(t('Relationships'), $contact_uri['path'] . '/relationships'),
  );
  drupal_set_breadcrumb($breadcrumb);
}