Magento Paypal Payflow Pro not being able to refund line items
If you are using Magento 1.7 and Paypal’s Payflow Pro you might have noticed that it does not let you refund line items on orders like you can do with other processors. Each processor class in Magento has a list of variables that define what it can and can’t do. For some reason Payflow Pro does not have $_canRefundInvoicePartial
enabled. This variable controls whether or not you can refund line items on an order. With it disabled your ability to issue refunds via a Credit Memo is severely limited. You are reduced to using convoluted math via the Adjustment field and the customer can’t see which items were refunded.
Fortunately the fix is fairly simple. First make sure your Payflow Pro account has reference transactions enabled. Then you’ll want to copy Payflow Pro payment class to your local directory. It is found in: /app/code/core/Mage/Paypal/Model/Payflowpro.php
After line 90 add
protected $_canRefundInvoicePartial = true; |
That’s it, you’re done. You can now use Credit Memos as they’re described in Magento’s own documentation. Simple select the Qty of the item to refund and click Refund.
Category: Magento, Payflow Pro, Paypal, PHP
Thanks, this worked perfectly for me. However, I found that the PayPal Manager setting for “reference transactions” does not need to be turned on in order for this to work.