Skip to content

Conversation

@mattsherman
Copy link
Contributor

@mattsherman mattsherman commented May 19, 2023

Submission Review Guidelines:

Changes proposed in this Pull Request:

This PR changes the empty state for the product variations tab for a Variable product with no "Used for variations" attributes to always show a message

Before

Would show when there were no "Used for variations" attributes on a product and there were global attributes in the system or non-variation attributes on the product.

Screenshot 2023-05-04 at 13 29 04

After

Shows whenever there are no "Used for variations" attributes on a product.

Screenshot 2023-05-19 at 00 21 49

Closes #38120.

How to test the changes in this Pull Request:

Using the WooCommerce Testing Instructions Guide, include your detailed testing instructions:

With both global attributes in the system and without....

  1. Go to Products > Add New
  2. Change product type to Variable
  3. Go to Variations tab
  4. Verify empty state
  5. Go to Attributes tab
  6. Add an attribute, marking as "Used for variations"
  7. Save attributes
  8. Go to Variations tab
  9. Verify the following is shown
Screenshot 2023-05-19 at 00 26 36

@mattsherman mattsherman self-assigned this May 19, 2023
@github-actions github-actions bot added the plugin: woocommerce Issues related to the WooCommerce Core plugin. label May 19, 2023
@mattsherman mattsherman added Enhancement The issue is a request for an enhancement. focus: product management [team:Mothra] and removed plugin: woocommerce Issues related to the WooCommerce Core plugin. labels May 19, 2023
@mattsherman mattsherman requested a review from a team May 19, 2023 04:29
@github-actions
Copy link
Contributor

github-actions bot commented May 19, 2023

Hi @nathanss, @woocommerce/mothra-enhancements

Apart from reviewing the code changes, please make sure to review the testing instructions as well.

You can follow this guide to find out what good testing instructions should look like:
https://github.com/woocommerce/woocommerce/wiki/Writing-high-quality-testing-instructions

@github-actions
Copy link
Contributor

Test Results Summary

Commit SHA: c0c2969

Test 🧪Passed ✅Failed 🚨Broken 🚧Skipped ⏭️Unknown ❔Total 📊Duration ⏱️
API Tests26700202690m 51s
E2E Tests1890010019915m 44s

To view the full API test report, click here.
To view the full E2E test report, click here.
To view all test reports, visit the WooCommerce Test Reports Dashboard.

@mattsherman mattsherman marked this pull request as ready for review May 19, 2023 04:44
@nathanss nathanss self-requested a review May 19, 2023 12:26
Copy link
Contributor

@nathanss nathanss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice job! Works as intended.

I love PRs that remove more code than add it :)

@mattsherman mattsherman merged commit ab77051 into trunk May 19, 2023
@mattsherman mattsherman deleted the update/variations-empty-state branch May 19, 2023 12:37
@github-actions github-actions bot added this to the 7.8.0 milestone May 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Enhancement The issue is a request for an enhancement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Enhancement]: Always show the variations empty state message when the number of attributes is 0

3 participants