Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix the error that is wrong link title of a downloadable product when enabling "Use Default Value" #27295

Conversation

tna274
Copy link
Contributor

@tna274 tna274 commented Mar 15, 2020

Description (*)

Fix the error that is wrong link title of a downloadable product when enabling "Use Default Value"

Related Pull Requests

N/A

Fixed Issues (if relevant)

#27169 - Not able to update value with "use default checkbox" for Downloadable Product

Manual testing scenarios (*)

  1. Create a new downloadable product with a link
  2. Choose scope at any store view (https://prnt.sc/rgpgs4)
  3. In "Downloadable Information" section, uncheck "Use Default Value" box under link title and change link title then saving product
  4. At the same product and scope, enable (check) "Use Default Value" box under link title then saving product

Questions or comments

Contribution checklist (*)

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • All automated tests passed successfully (all builds are green)

@m2-assistant
Copy link

m2-assistant bot commented Mar 15, 2020

Hi @tna274. Thank you for your contribution
Here is some useful tips how you can test your changes using Magento test environment.
Add the comment under your pull request to deploy test or vanilla Magento instance:

  • @magento give me test instance - deploy test instance based on PR changes
  • @magento give me 2.4-develop instance - deploy vanilla Magento instance

For more details, please, review the Magento Contributor Guide documentation.

Copy link
Contributor

@eduard13 eduard13 left a comment

Choose a reason for hiding this comment

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

Hi @tna274, thank you for your contribution, could you please review the minor recommendation?
Could you please also check and fix the failing Static Tests?
Thank you.

app/code/Magento/Downloadable/Model/Link/Builder.php Outdated Show resolved Hide resolved
@eduard13 eduard13 added the Auto-Tests: Covered All changes in Pull Request is covered by auto-tests label Mar 16, 2020
tna274 and others added 7 commits March 16, 2020 22:48
… enabling "Use Default Value"

- Fix unit test for the function that was fixed
Update app/code/Magento/Downloadable/Model/Link/Builder.php

Co-Authored-By: Eduard Chitoraga <e.chitoraga@atwix.com>
… enabling "Use Default Value"

- Revert incorrect file
… enabling "Use Default Value"

- Update unit test
… enabling "Use Default Value"

- Fix static code
… enabling "Use Default Value"

- Fix static code
… enabling "Use Default Value"

- Fix static code
@tna274
Copy link
Contributor Author

tna274 commented Mar 18, 2020

Hi @eduard13
Could you help me check the functional test. I found some failure test in report but they do not relate to my edited code.
The uncompleted tests relate to cms_block_page and simple product on frontend.

eduard13
eduard13 previously approved these changes Mar 18, 2020
Copy link
Contributor

@eduard13 eduard13 left a comment

Choose a reason for hiding this comment

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

Indeed, the failing tests aren't related to these changes.

@magento-engcom-team
Copy link
Contributor

Hi @eduard13, thank you for the review.
ENGCOM-7137 has been created to process this Pull Request

@magento-engcom-team
Copy link
Contributor

@tna274 thank you for contributing. Please accept Community Contributors team invitation here to gain extended permissions for this repository.

Copy link
Contributor

@engcom-Alfa engcom-Alfa left a comment

Choose a reason for hiding this comment

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

Hi, @tna274.

During testing, we faced the issue.

Problem: Not able to update the Samples Title by "Use Default Value" checkbox

Manual testing scenario:

  1. Create a new downloadable product with a link and sample;
  2. Save the product;
    screen1
  3. Choose scope at any store view;
    screenshot2
  4. In "Downloadable Information" section, uncheck "Use Default Value" boxes under link title and sample title, and change the values.
  5. Save the product;
    screenshot3
  6. Now, check "Use Default Value" boxes under the link and sample titles;
  7. Save the product;

Actual Result:
✖️ The default value for the link title was saved but for the sample title was not.
screenshot4

@tna274 Could you take a look?

Thanks!

@ghost ghost dismissed eduard13’s stale review March 18, 2020 12:37

Pull Request state was updated. Re-review required.

@tna274
Copy link
Contributor Author

tna274 commented Mar 19, 2020

Hi @engcom-Alfa
I've been update PR, please check it again.

@engcom-Alfa
Copy link
Contributor

Hi,@eduard13. Could you review the latest changes? Thanks!

@engcom-Alfa engcom-Alfa requested a review from eduard13 March 19, 2020 05:55
@magento-engcom-team
Copy link
Contributor

Hi @eduard13, thank you for the review.
ENGCOM-7137 has been created to process this Pull Request

@engcom-Alfa
Copy link
Contributor

✔️ QA Passed

@engcom-Kilo
Copy link
Contributor

@magento run Functional Tests B2B, @magento run Functional Tests CE, @magento run Functional Tests EE

@engcom-Echo
Copy link
Contributor

@magento run all tests

magento-engcom-team pushed a commit that referenced this pull request Apr 4, 2020
@magento-engcom-team magento-engcom-team merged commit 5a44486 into magento:2.4-develop Apr 4, 2020
@m2-assistant
Copy link

m2-assistant bot commented Apr 4, 2020

Hi @tna274, thank you for your contribution!
Please, complete Contribution Survey, it will take less than a minute.
Your feedback will help us to improve contribution process.

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

Successfully merging this pull request may close these issues.

6 participants