civicrm/civicrm-drupal — pull request #40 by torrance (2013-07-16 00:27:56+00:00)
Title: Allow joining to the civicrm_relationship table via either contact_id_a or contact_id_b

Previously the civicrm_contact table was implicitly joined to the civicrm_relationship table via the contact_id_a field. This made it impossible to join via the contact_id_b field.

This patch removes this implicit join and instead adds two relationships to the civicrm_contact table, allowing a user to decide how to join to the civicrm_relationship table.

This patch also standardises the use of views_handler_relationship over civicrm_handler_relationship, as this is a mess of code and as it is not being used, could probably be removed altogether.