CRM-16735 fixes - PCP notification email should not be sent when contribution record...
authoryashodha <yashodha.chaku@webaccessglobal.com>
Tue, 7 Jul 2015 11:35:42 +0000 (17:05 +0530)
committeryashodha <yashodha.chaku@webaccessglobal.com>
Tue, 7 Jul 2015 11:35:42 +0000 (17:05 +0530)
https://issues.civicrm.org/jira/browse/CRM-16735

CRM/Contribute/Form/Contribution.php

index cc2376f24adb65e4a2e528772fe7b0c36af2a7c6..31443e6971879f84d8fb3d05e828e3df477f35fc 100644 (file)
@@ -1153,7 +1153,7 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP
     $isEmpty = array_keys(array_flip($submittedValues['soft_credit_contact_id']));
     if ($this->_id && count($isEmpty) == 1 && key($isEmpty) == NULL) {
       //Delete existing soft credit records if soft credit list is empty on update
-      CRM_Contribute_BAO_ContributionSoft::del(array('contribution_id' => $this->_id));
+      CRM_Contribute_BAO_ContributionSoft::del(array('contribution_id' => $this->_id, 'pcp_id' => 0));
     }
     else {
       //build soft credit params