From: Jamie McClelland Date: Tue, 28 Oct 2014 21:21:28 +0000 (-0400) Subject: CRM-15537 - translate open ended installments to 9999 for authorize.net X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=702c12037f3dadc163474e1e8166a795fa228a9d;p=civicrm-core.git CRM-15537 - translate open ended installments to 9999 for authorize.net ---------------------------------------- * CRM-15537: editing recurring contribution for authorize.net with unlimited contributions throws error https://issues.civicrm.org/jira/browse/CRM-15537 --- diff --git a/CRM/Core/Payment/AuthorizeNet.php b/CRM/Core/Payment/AuthorizeNet.php index 16d2b6d7ef..8fbacdffc5 100644 --- a/CRM/Core/Payment/AuthorizeNet.php +++ b/CRM/Core/Payment/AuthorizeNet.php @@ -757,7 +757,11 @@ class CRM_Core_Payment_AuthorizeNet extends CRM_Core_Payment { $template->assign('paymentKey', $this->_getParam('paymentKey')); $template->assign('subscriptionId', $params['subscriptionId']); - $template->assign('totalOccurrences', $params['installments']); + + // for open ended subscription totalOccurrences has to be 9999 + $installments = empty($params['installments']) ? 9999 : $params['installments']; + $template->assign('totalOccurrences', $installments); + $template->assign('amount', $params['amount']); $arbXML = $template->fetch('CRM/Contribute/Form/Contribution/AuthorizeNetARB.tpl');