From: Eileen Date: Fri, 3 Jan 2014 06:43:18 +0000 (+1300) Subject: Member BAO class E-Notice identified in test X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=79022644a7d3c98f19be803ac1143fadb78b74dd;p=civicrm-core.git Member BAO class E-Notice identified in test --- diff --git a/CRM/Member/BAO/Membership.php b/CRM/Member/BAO/Membership.php index 5ba8d740fc..3b013a09a2 100644 --- a/CRM/Member/BAO/Membership.php +++ b/CRM/Member/BAO/Membership.php @@ -1550,11 +1550,15 @@ AND civicrm_membership.is_test = %2"; //decide status here, if needed. $updateStatusId = NULL; - + $membershipID = NULL; + //@todo would be better to accept $membershipID as an FN param & make form layer responsible for extracting it + if(isset($form->_membershipId)) { + $membershipID = $form->_membershipId; + } // CRM-7297 - allow membership type to be be changed during renewal so long as the parent org of new membershipType // is the same as the parent org of an existing membership of the contact $currentMembership = CRM_Member_BAO_Membership::getContactMembership($contactID, $membershipTypeID, - $is_test, $form->_membershipId, TRUE + $is_test, $membershipID, TRUE ); if ($currentMembership) { $activityType = 'Membership Renewal';