The role renewal on the site I have set up isn't working. I did some troubleshooting and tracked it down to the fact that the payment history in the PayflowProRecurring class isn't getting populated as an array of payments in the load() method. It's only assigning the first payment into payment_history.

$payment->RPPaymentResult in the load() method is an array that's not treated like one. So in cron, when it checks if the new pfp_rpref is different than the old, it always evaluates to false, because both the pfp_rpref in the database and the 'last payment' are always the ref # for the first payment.

Did something change about the Payflow API or is this working for other people? Granted this could be something that doesn't occur for other sites, because I've imported old payflow pro into a Drupal installation, but I don't see how the role renewal worked in this current state.

Comments

cwithout’s picture

Status: Active » Needs review
StatusFileSize
new1.05 KB
new1.04 KB
cwithout’s picture

If anybody can tell me if this is an issue for them or if someone has actually got recurring payments to work using Payflow, that'd be great.

cwithout’s picture

I confirmed this is also not working on a fresh install. And it's the reason that in payment history for each Payflow Pro profile only the first payment would ever show up (seen at the paths: user/[uid]/pfp_cpanel/[profile_id]/view or admin/store/settings/uc_recurring/administer/[profile_id]/view).

With the the above patch, the $payment_history array is populated with all payments instead of just the one.

I couldn't tell why you were turning $history into an array and then doing a foreach on it when it seems there would only ever be one element in that array. I didn't want to mess with it in case there's a good reason, so I left it as is.

I know you're working using a different method for recurring payments, but it would be great if this worked in the mean time.

kwinters’s picture

Issue summary: View changes
Status: Needs review » Closed (duplicate)