Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Show current selected attributes when re-edit Products by Attribute block #3185

Merged
merged 1 commit into from
Oct 14, 2020

Conversation

farookibrahim
Copy link
Contributor

@farookibrahim farookibrahim commented Sep 23, 2020

Fixes #3084

To reproduce

Steps to reproduce the behavior:

  1. Add a Products by Attribute block.
  2. Select some attributes and click on Done.
  3. Click on the pencil icon to edit the block again.
  4. Notice the attributes you previously selected are not checked by default, so it's easy to forget what was your previous attribute selection.

Expected behavior

When clicking on the edit button, the currently selected attributes should be checked by default, like it happens with the Products by Category block, for example.

How to test the changes in this Pull Request:

  1. Add a Products by Attribute block.
  2. Select some attributes and click on Done.
  3. Click on the pencil icon to edit the block again.
  4. Now selected attributes checked by default.

Screenshots:

91700882-cad75780-eb76-11ea-9257-c339e7d8bb4a.gif

ezgif com-video-to-gif

@farookibrahim farookibrahim requested a review from a team as a code owner September 23, 2020 07:17
@farookibrahim farookibrahim requested review from Aljullu and removed request for a team September 23, 2020 07:17
@senadir
Copy link
Member

senadir commented Sep 23, 2020

Hi Farook, Thank you for your contribution! can you please you update:

  • The PR title to outline what you fixed
  • The PR body to explain what was fixed and how to test those changes (copying from the issue is okay).

@senadir senadir added type: bug The issue/PR concerns a confirmed bug. block: products by attribute Issues related to the Products by Attribute block. labels Sep 23, 2020
@farookibrahim farookibrahim changed the title Fixed: #3084 Fixed issue current values doesn't persist in Products by Attribute block Sep 23, 2020
@farookibrahim
Copy link
Contributor Author

Hi @senadir, I updated the title and comment now.

@nerrad nerrad requested review from senadir and removed request for Aljullu September 24, 2020 15:38
@nerrad nerrad changed the base branch from main to trunk September 26, 2020 17:29
Copy link
Member

@senadir senadir left a comment

Choose a reason for hiding this comment

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

Hi @farookibrahim, sorry for taking so long to get back at this, I tested it and it works as expected.
Thank you for your contribution!

@senadir senadir merged commit 310bc44 into woocommerce:trunk Oct 14, 2020
@Aljullu Aljullu added this to the 3.7.0 milestone Oct 15, 2020
@haszari haszari changed the title Fixed issue current values doesn't persist in Products by Attribute block Show current selected attributes when re-edit Products by Attribute block Oct 28, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
block: products by attribute Issues related to the Products by Attribute block. type: bug The issue/PR concerns a confirmed bug.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Products by Attribute block doesn't persist the current values when clicking on edit button
5 participants