PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

Issue Refund by Vendor sets entry to "Pending"

  1. mipapage
    Member

    Hi there,

    I have all of the most recent versions of GF and the PayPal addon, as well as WP. I've set up a sandbox vendor and buyer and can purchase properly. For fun I entered the vendor account and clicked "issue refund" for a sale, and the entry in the GF form data then reflected a status of Pending (previously Approved) with a -ve dollar amount equal to the sale value in the "Payment Amount" area.

    We're looking to hook this into our CRM, but for now it would be cool if this could reflect a status of "Vendor Refunded" or similar.

    Posted 12 years ago on Tuesday July 31, 2012 | Permalink
  2. David Peralty

    Gravity Forms doesn't make such distinctions as refunds and other payment status types were never taken into consideration. Gravity Forms is not an e-commerce solution, but instead allows simple e-commerce functions. I will let out developers know about this though, and see if we can add this in an upcoming version.

    Posted 12 years ago on Tuesday July 31, 2012 | Permalink
  3. mipapage
    Member

    Thanks David,

    Its pretty clear that GF is still listening to the IPN when this happens, it is even updating the price, so yes, that would be good.

    Simply Integrating with what the IPN offers doesn't even come close to an e-commerce solution. Though it is clear here that this simply "Automatically transfer[s] the user to complete the PayPal transaction when a form is submitted", it seems some low hanging fruit to handle and make a decent product complete!

    Posted 12 years ago on Tuesday July 31, 2012 | Permalink
  4. David Peralty

    You are correct, we are still listening to it for payment status changes. Some other statuses we probably aren't listening to are related to the user requesting the a refund, refund given, etc... Like I said, I'll double check with the development team on these.

    Posted 12 years ago on Tuesday July 31, 2012 | Permalink
  5. mipapage
    Member

    Thanks David,

    Also, how does one get this debugging log add on? I'd like to run this while we get going here in case we run into any issues...

    Thanks!

    Posted 12 years ago on Tuesday July 31, 2012 | Permalink
  6. David Peralty

    I've e-mailed you about the add-on.

    Posted 12 years ago on Tuesday July 31, 2012 | Permalink
  7. mipapage
    Member

    Thanks David,

    Trolling thru the paypal.php code, the following case looks like it should have handled the status update...

    case "refunded" :
                            self::log_debug("Processing a Refund request.");
                            if($entry["payment_status"] != "Refunded"){
                                if($entry["transaction_type"] == 1){
                                    $entry["payment_status"] = "Refunded";
                                    self::log_debug("Setting entry as Refunded.");
                                    RGFormsModel::update_lead($entry);
                                }
                                RGFormsModel::add_note($entry["id"], $user_id, $user_name, sprintf(__("Payment has been refunded. Refunded amount: %s. Transaction Id: %s", "gravityforms"), $amount, $transaction_id));
                            }
    
                            GFPayPalData::insert_transaction($entry["id"], "refund", $subscriber_id, $transaction_id, $parent_transaction_id, $amount);
                        break;

    I may be wrong there and have no clue why it would have grabbed the pending status instead...

    Posted 12 years ago on Thursday August 2, 2012 | Permalink
  8. David Peralty

    I've already e-mailed the developers about this. They might need to contact you to log in and see the issue for themselves. Can you e-mail me at peralty@rocketgenius.com an admin login to the site?

    Posted 12 years ago on Thursday August 2, 2012 | Permalink
  9. mipapage
    Member

    Hmm.. This is a client site, can I simply pass them a log file from the logger?

    Posted 12 years ago on Thursday August 2, 2012 | Permalink
  10. David Peralty

    Sure, but if they can't replicate the issue or find the source, then I may need to work with you on getting access to find the reason.

    Posted 12 years ago on Thursday August 2, 2012 | Permalink
  11. mipapage
    Member

    Okay, I'm about to run some tests and will email you the log file. Off to fire up three browsers and lg into the sandbox...

    Posted 12 years ago on Thursday August 2, 2012 | Permalink