strangerstudios / paid-memberships-pro

WordPress membership plugin to restrict access to content and charge recurring subscriptions using Stripe, PayPal, and more. Fully open source. 100% GPL.
https://www.paidmembershipspro.com
Other
457 stars 357 forks source link

Orders page does not show updated status of order #2239

Open michaelbeil opened 1 year ago

michaelbeil commented 1 year ago

Describe the bug If you cancel an order, it will show as canceled from that specific page for the order, but if you visit the Memberships > Orders page, it will have the old status.

To Reproduce Steps to reproduce the behavior:

  1. Go to Memberships > Orders
  2. Click on an order
  3. Scroll down to status and cancel
  4. See that the status is updated on the Edit Order page, but not on the Memberships > Orders page.

Screenshots image image

Expected behavior The status should be updated on the Memberships > Orders page.

This came up in ticket 446025 and I was able to replicate.

We cancelled an order on the Membership Order-Lists over their detail page. But why does it still show it on the overview page es paid and not cancelled? Isolating the problem:

  • [x] I have deactivated other plugins and confirmed this bug occurs when only Paid Memberships Pro plugin is active.
  • [x] This bug happens with a default WordPress theme active, or Memberlite.
  • [x] I can reproduce this bug consistently using the steps above.

WordPress Environment

``` Paid Memberships Pro 2.9.4, WordPress 6.0.2, PHP 7.4.1 ```
mircobabini commented 1 year ago

"Feature not a bug" situation.

In the orders list we are not showing the order status; we are showing Paid, which means that it's paid in both success/cancelled status.

I agree that we should rollback and show the order status though.

ideadude commented 1 year ago

I'll leave this open for discussion in case some intermediate solution comes up.

This is a "subs table fixes this" situation. We currently track both the status of the order AND the subscription in the order status (long story, old code). When we merge the subs table work for version 3.0, this will show the order status (which will be success whether the sub was cancelled or not) and have an extra column I believe to mention the relation subscription.

I agree it's confusing now to not show "cancelled" when that is the literal status of the order, but we do similar adjustments to values to make them more legible in the table view. People are equally confused when an order says "cancelled" but that really means the sub is cancelled and the order is okay.

Another way to think about it is that it's the edit order page that is incorrect. The status there should be success, but we need subs table to manage the sub before we can do that.

I think we should leave it as "paid" here since that's closest to how it's going to work with PMPro 3.0+

I'm sympathetic to hearing workflows where this is confusing (I can't find the cancelled subscription) and trying to figure out ways to address that.

kimwhite commented 1 year ago

Is there any way to change this not to say "paid" if it really is a canceled order? It's very confusing. Another setting? something?

mircobabini commented 1 year ago

In my setup I changes the label color to gray in that case. This may become a snippet at least.

Still a fan on changing this behaviour somehow until we have the subs table.

kimwhite commented 1 year ago

It seems if you mark an incomplete order to ERROR you will get the desired result.