Commit 9ea2a8d8 authored by jaapjansma's avatar jaapjansma
Browse files

Update related membership when create relationship or create/update...

Update related membership when create relationship or create/update relationship action is performed.
parent e5beaf9b
Version 1.6 (not yet released)
* Update related membership when create relationship or create/update relationship action is performed.
Version 1.5
------------------------------
......
......@@ -116,7 +116,7 @@ class CreateOrUpdateRelationship extends CreateRelationship {
try {
// Do not use api as the api checks for an existing relationship.
$relationship = \CRM_Contact_BAO_Relationship::add($relationshipParams);
$relationship = \CRM_Contact_BAO_Relationship::create($relationshipParams);
$output->setParameter('id', $relationship->id);
} catch (\Exception $e) {
// Do nothing.
......@@ -124,4 +124,4 @@ class CreateOrUpdateRelationship extends CreateRelationship {
}
}
}
\ No newline at end of file
}
......@@ -129,11 +129,11 @@ class CreateRelationship extends AbstractAction {
}
try {
// Do not use api as the api checks for an existing relationship.
$relationship = \CRM_Contact_BAO_Relationship::add($relationshipParams);
$relationship = \CRM_Contact_BAO_Relationship::create($relationshipParams);
$output->setParameter('id', $relationship->id);
} catch (\Exception $e) {
// Do nothing.
}
}
}
\ No newline at end of file
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment