Skip to content

Conversation

@chihsuan
Copy link
Member

@chihsuan chihsuan commented Sep 27, 2022

All Submissions:

Changes proposed in this Pull Request:

Closes #34765.

This PR adds wrap Industry in a loader component to ensure it's rendered after all required data are fetched to populate checkboxes properly.

It doesn't show selected options because the options are populated in the constructor when profile items are loading.

constructor( props ) {
const profileItems = get( props, 'profileItems', {} );
let selected = profileItems.industry || [];

How to test the changes in this Pull Request:

  1. Go to OBW
  2. Fill store details and click on "continue" button.
  3. On "Industry" tab select one or more option and click on "continue" button.
  4. Click on previous "Industry" tab.
  5. Reload the page
  6. Observe that selected "Industry" options are shown in the Industry step after reloading the page for OBW.

Other information:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes, as applicable?
  • Have you successfully run tests with your changes locally?
  • Have you created a changelog file for each project being changed, ie pnpm changelog add --filter=<project>?

FOR PR REVIEWER ONLY:

  • I have reviewed that everything is sanitized/escaped appropriately for any SQL or XSS injection possibilities. I made sure Linting is not ignored or disabled.

@github-actions github-actions bot added focus: react admin plugin: woocommerce Issues related to the WooCommerce Core plugin. labels Sep 27, 2022
@chihsuan chihsuan self-assigned this Sep 27, 2022
@chihsuan chihsuan requested a review from a team September 27, 2022 06:15
@github-actions
Copy link
Contributor

Test Results Summary

Commit SHA: 0a02173

Test 🧪Passed ✅Failed 🚨Broken 🚧Skipped ⏭️Unknown ❔Total 📊Duration ⏱️
API Tests11800201200m 58s
E2E Tests185002018712m 37s
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.

Copy link
Contributor

@ilyasfoo ilyasfoo left a comment

Choose a reason for hiding this comment

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

Tests well, LGTM! 🚢

@chihsuan chihsuan merged commit c31f8b0 into trunk Sep 27, 2022
@chihsuan chihsuan deleted the fix/34765-industry-reloading-page branch September 27, 2022 08:26
@github-actions github-actions bot added this to the 7.1.0 milestone Sep 27, 2022
@github-actions
Copy link
Contributor

Hi @chihsuan, thanks for merging this pull request. Please take a look at these follow-up tasks you may need to perform:

  • Add the release: add testing instructions label

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

plugin: woocommerce Issues related to the WooCommerce Core plugin.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[GlobalStep] "Industry" options fails to save in the Industry step after reloading the page for OBW.

3 participants