[#20] make sure recurring contribution ID also present if SEPA mandate
This commit is contained in:
commit
0e8534619e
1 changed files with 3 additions and 1 deletions
|
@ -707,13 +707,15 @@ function civicrm_api3_twingle_donation_Submit($params) {
|
||||||
$recurring_contribution_id = $contribution_id = '';
|
$recurring_contribution_id = $contribution_id = '';
|
||||||
if (isset($contribution_recur['id'])) {
|
if (isset($contribution_recur['id'])) {
|
||||||
$recurring_contribution_id = $contribution_recur['id'];
|
$recurring_contribution_id = $contribution_recur['id'];
|
||||||
|
} elseif (!empty($mandate['entity_id']) && $mandate['type'] == 'RCUR') {
|
||||||
|
$recurring_contribution_id = $mandate['entity_id'];
|
||||||
}
|
}
|
||||||
if (isset($contribution['id'])) {
|
if (isset($contribution['id'])) {
|
||||||
$contribution_id = $contribution['id'];
|
$contribution_id = $contribution['id'];
|
||||||
}
|
}
|
||||||
|
|
||||||
// run the call
|
// run the call
|
||||||
civicrm_api3($pp_entity, $pp_action, [
|
civicrm_api3(trim($pp_entity), trim($pp_action), [
|
||||||
'membership_id' => $membership['id'],
|
'membership_id' => $membership['id'],
|
||||||
'contact_id' => $contact_id,
|
'contact_id' => $contact_id,
|
||||||
'organization_id' => isset($organisation_id) ? $organisation_id : '',
|
'organization_id' => isset($organisation_id) ? $organisation_id : '',
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue