From: Sudha Bisht Date: Fri, 7 Aug 2015 11:08:00 +0000 (+0530) Subject: Fix for multiple role assignment between cases X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=ef6463ad1ba5469fa27470eafd55d2571bfd0ef2;p=civicrm-core.git Fix for multiple role assignment between cases --- diff --git a/CRM/Contact/BAO/Relationship.php b/CRM/Contact/BAO/Relationship.php index c8f5362d5f..dd1f1305f2 100644 --- a/CRM/Contact/BAO/Relationship.php +++ b/CRM/Contact/BAO/Relationship.php @@ -189,6 +189,10 @@ class CRM_Contact_BAO_Relationship extends CRM_Contact_DAO_Relationship { continue; } + //CRM-16978:check duplicate relationship as per case id. + if ($caseId = CRM_Utils_Array::value('case_id', $params)) { + $contactFields['case_id'] = $caseId; + } if ( self::checkDuplicateRelationship( $contactFields,