Added possibility to skip the recent view list when creating a relationship.
authorMattias Michaux <mattias.michaux@gmail.com>
Mon, 2 Nov 2015 14:59:20 +0000 (15:59 +0100)
committerMattias Michaux <mattias.michaux@gmail.com>
Mon, 2 Nov 2015 14:59:20 +0000 (15:59 +0100)
CRM/Contact/BAO/Relationship.php

index c762b65dc8986a0cb513effda67c485098ff907c..9c187c6c1896e75e553e4df53f291ebe3ca7e004 100644 (file)
@@ -83,7 +83,10 @@ class CRM_Contact_BAO_Relationship extends CRM_Contact_DAO_Relationship {
       self::disableEnableRelationship($id, $action, $params, $ids, $active);
     }
 
-    self::addRecent($params, $relationship);
+    if (empty($params['skipRecentView'])) {
+      self::addRecent($params, $relationship);
+    }
+
     return $relationship;
   }