Automattic / woocommerce-subscriptions-core

Subscriptions core package for WooCommerce
Other
80 stars 29 forks source link

Fix subscription table is empty in mobile view when HPOS is enabled. #610

Closed Mayisha closed 1 month ago

Mayisha commented 2 months ago

Fixes #584

This PR fixes to issues related to HPOS-

How to test this PR

  1. Enable HPOS from WooCommerce > Settings > Advanced > Features page.
  2. Create at least one subscription.
  3. Go to WooCommerce > Subscriptions.
  4. Notice that the subscription is present in the table.
  5. In trunk branch, inspect at a mobile breakpoint (max-width: 782 px). Notice that the table is empty.
  6. Also, the WooCommerce page header is missing on the Subscriptions page.
  1. In this branch, inspect at a mobile breakpoint (max-width: 782 px). Notice that the subscriptions are rendered correctly in the table.
  2. In this branch, the WooCommerce page header is present on the Subscriptions page for both desktop and mobile views.
Mayisha commented 2 months ago

@james-allan with the new Gutenberg release, the minimum supported version of PHP is 7.2. Two of the tests are failing because of this. Shall we remove the tests with PHP 7.1 and older versions? Do we still need to support these older versions of PHP? :eyes:

mattallan commented 1 month ago

Shall we remove the tests with PHP 7.1 and older versions? Do we still need to support these older versions of PHP? 👀

Good call! The oldest WooCommerce we support (7.7) requires PHP 7.3 so I don't think we need to support these older versions anymore.

I've updated the GH workflows in a separate PR (https://github.com/Automattic/woocommerce-subscriptions-core/pull/612). I'll merge this once I confirm the tests are running smoothly :)

mattallan commented 1 month ago

Thanks @Mayisha for these changes! CH checks are passing, so I'm going to merge this now 🙌

Mayisha commented 1 month ago

Thanks @mattallan :tada: