Contribution page with recurring payment and Separate membership payment fails to pass contributionRecurID
Overview
Sorry for the long title
Contribution pages which are setup with recurring memberships, additional contribution amounts, and separate membership payment result in no contributionRecurID
being setup and therefore (in the case of iATS) no recurring payment setup.
In the case of iATS, and probably other payment processors, this ID is actually used to setup the recurring payment. Ironicaly, the is_recur is being passed so this seems clearly a bug.
Reproduction steps
- Create a Membership Contribution page
- Check-off Contribution Amounts section enabled
- Add a few additional contribution amounts
- Don't set recurring for the Contribution Amounts (although another interesting testing scenario)
- Add a Membership with the option to renew
- Check off Separate Membership payment_ <== this is the key
- Use this form (test or live)
- Choose not to add an additional contribution
- Choose your membership and check-off auto-renew
- Process the form
- No client code is returned, client is set as auto-renew but there is no payment token setup (
contributionRecurID
)
Current behaviour
The following occurs:
- Membership transaction is made with
is_recur
set, but nocontributionRecurID
set - Transaction completes, but no recurring account is created (at least for iATS) because of missing ID
Ironically, turning off the Separate Contribution Amount
results in the ID to be created, and everything runs smoothly. The problem with this scenario is there are loads of people who might want to do a one-time donation, but not have that repeat each year.
nov. 10 19:06:12 [warning] params array (
'qfKey' => 'cut',
'entryURL' => 'cut',
'email-Primary' => 'cut',
'first_name' => 'Administrateur',
'last_name' => 'SymbioTIC',
'street_address-1' => '312312',
'city-1' => '312',
'postal_code-1' => '312',
'country-1' => '1039',
'state_province-1' => '1110',
'phone-Primary-1' => '321312',
'preferred_language' => 'fr_CA',
0 => '',
1 => '',
'group' =>
array (
2 => '',
3 => '',
),
'custom_11' => 'test',
'contact_sub_type_hidden' => 'Membre_ami',
'hidden_processor' => '1',
'credit_card_number' => 'testcc',
'cvv2' => '123',
'credit_card_exp_date' =>
array (
'm' => '5',
'Y' => '2032',
),
'credit_card_type' => 'Visa',
'billing_first_name' => 'Administrateur',
'billing_middle_name' => '',
'billing_last_name' => 'SymbioTIC',
'billing_street_address-5' => '312312',
'billing_city-5' => '312',
'billing_state_province_id-5' => '1110',
'billing_postal_code-5' => '312',
'billing_country_id-5' => '1039',
'payment_processor_id' => '4',
'auto_renew' => true,
'priceSetId' => '9',
'price_16' => '60',
'price_18' => '-1',
'selectProduct' => '',
'MAX_FILE_SIZE' => '83886080',
'ip_address' => 'cut',
'amount' => '30.000000000',
'amount_level' => 'null',
'selectMembership' => '4',
'year' => '2032',
'month' => '5',
'card_type_id' => 1,
'pan_truncation' => '2220',
'currencyID' => 'CAD',
'is_pay_later' => 0,
'is_recur' => 1,
'frequency_interval' => '1',
'frequency_unit' => 'year',
'invoiceID' => 'cut',
'is_quick_config' => 1,
'email-5' => 'cut',
'description' => 'Contribution en ligne: Adhésion Membre Ami',
'accountingCode' => NULL,
'is_test' => 1,
'campaign_id' => NULL,
'middle_name' => '',
'email' => 'cut',
'street_address' => '312312',
'city' => '312',
'state_province' => 'QC',
'postal_code' => '312',
'country' => 'CA',
'cms_contactID' => '2',
'skipLineItem' => 1,
'total_amount' => '30.000000000',
'tax_amount' => 0.0,
'contactID' => '2',
'financialTypeID' => '2',
'trxn_id' => NULL,
'contributionID' => 384,
)
nov. 10 19:06:12 [warning] is_recur: false
Expected behaviour
- Choosing
Separate Contribution Amount
should not lead to a missing ContributionRecurID - ID is passed and a recurring account is created properly