Standardisation/fix when calling changeSubscriptionAmount
2 unresolved threads
2 unresolved threads
The changeSubscriptionAmount
function wasn't documented at all until last week...
Merge request reports
Activity
249 249 public function changeSubscriptionAmount(array $changeActivity, array $recur, CRM_Core_Payment $paymentProcessorObject) :string { 250 250 // Old (current, as of 5.49) method 251 251 $message = ''; 252 $newAmount = $changeActivity['updaterecur_activity_fields.updaterecur_new_amount']; 249 249 public function changeSubscriptionAmount(array $changeActivity, array $recur, CRM_Core_Payment $paymentProcessorObject) :string { 250 250 // Old (current, as of 5.49) method 251 251 $message = ''; 252 $newAmount = $changeActivity['updaterecur_activity_fields.updaterecur_new_amount']; 253 // contributionRecurID is the "correct" parameter per propertyBag, but it wasn't well defined before 5.70 254 // so we need to pass in id as well as some PaymentProcessors will expect that. 255 // Older payment processors will still expect `subscriptionId` which is really processor_id but we don't support that. 252 256 $paymentProcessorObject->changeSubscriptionAmount($message, [ 257 'contributionRecurID' => $recur['id'], mentioned in commit 2e271402
Thanks @mattwire
Please register or sign in to reply