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

Issue #27925, moved the submit button to the inside of the <form> #28172

Merged
merged 12 commits into from
Oct 21, 2020

Conversation

vestman
Copy link
Contributor

@vestman vestman commented May 9, 2020

Description (*)

Placing the submit button inside the <form id="purchaseorder-form"...></form> makes implicit submission[1] possible without altering any JS.
[1] - https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#implicit-submission

Related Pull Requests

https://github.com/magento/partners-magento2b2b/pull/417

Fixed Issues (if relevant)

  1. Fixes Checkout: Placing an order using the enter key causes a redirect to the checkout #27925: Checkout: Placing an order using the enter key causes a redirect to the checkout

Manual testing scenarios (*)

  1. Add a product to the cart and proceed to the checkout
  2. Enter your shipping details and proceed to "Review & Payments"
  3. Select "Purchase Order" as your payment of choice
  4. Enter a random "Purchase Order Number"
  5. Press enter while the focus is still on the "Purchase Order Numer" field

Expected result

The form should be submitted (and validated) on keyboard Enter. Order is placed.

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)

Placing the submit button inside the `<form id="purchaseorder-form"...></form>` makes implicit submission possible
@m2-assistant
Copy link

m2-assistant bot commented May 9, 2020

Hi @vestman. 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.

@vestman
Copy link
Contributor Author

vestman commented May 9, 2020

@magento give me test instance

@magento-engcom-team
Copy link
Contributor

Hi @vestman. Thank you for your request. I'm working on Magento instance for you

@dmytro-ch dmytro-ch self-assigned this May 10, 2020
@dmytro-ch dmytro-ch added the Auto-Tests: Not Covered Changes in Pull Request requires coverage by auto-tests label May 10, 2020
Copy link
Contributor

@dmytro-ch dmytro-ch left a comment

Choose a reason for hiding this comment

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

Hello @vestman, thank you for your contribution. Due to Magento Definition of Done the changes should be covered by tests. Could you please cover your fix by an automated test? I think in this particular case the Functional test is preferable.
Thank you!

@ghost ghost moved this from Pending Review to Changes Requested in Pull Requests Dashboard May 10, 2020
@engcom-Kilo engcom-Kilo self-assigned this May 12, 2020
@engcom-Kilo
Copy link
Contributor

Working on MFTF test

@engcom-Kilo
Copy link
Contributor

Added MFTF tests.

@engcom-Kilo
Copy link
Contributor

@magento run all tests

@vestman
Copy link
Contributor Author

vestman commented May 20, 2020

@magento run all tests

@VladimirZaets VladimirZaets added Priority: P3 May be fixed according to the position in the backlog. Severity: S2 Major restrictions or short-term circumventions are required until a fix is available. labels Jun 25, 2020
@engcom-Kilo
Copy link
Contributor

@magento run all tests

@lenaorobei lenaorobei moved this from Changes Requested to Pending Review in Pull Requests Dashboard Aug 19, 2020
@ghost ghost removed the Progress: needs update label Aug 19, 2020
@engcom-Alfa
Copy link
Contributor

✔️ QA Passed

Precondition:

Enable "Purchase Order" as a payment method

Manual testing scenario:

  1. Add a product to the cart and proceed to the checkout
  2. Enter your shipping details and proceed to "Review & Payments"
  3. Select "Purchase Order" as your payment of choice
  4. Enter a random "Purchase Order Number"
  5. Press enter while the focus is still on the "Purchase Order Numer" field

After: ✔️ The form is submitted on the Enter keyboard and the order is placed

Peek 2020-10-13 14-03

@engcom-Alfa engcom-Alfa moved this from Testing in Progress to Extended Testing (optional) in Pull Requests Dashboard Oct 13, 2020
@engcom-Charlie engcom-Charlie moved this from Extended Testing (optional) to Merge in Progress in Pull Requests Dashboard Oct 15, 2020
@ghost ghost moved this from Merge in Progress to Ready for Testing in Pull Requests Dashboard Oct 16, 2020
@ghost ghost assigned gabrieldagama Oct 16, 2020
@magento-engcom-team
Copy link
Contributor

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

@ihor-sviziev
Copy link
Contributor

@gabrieldagama seems like now we have incorrect status

@engcom-Alfa engcom-Alfa moved this from Ready for Testing to Testing in Progress in Pull Requests Dashboard Oct 16, 2020
@engcom-Alfa engcom-Alfa moved this from Testing in Progress to Extended Testing (optional) in Pull Requests Dashboard Oct 16, 2020
@engcom-Alfa engcom-Alfa moved this from Extended Testing (optional) to Merge in Progress in Pull Requests Dashboard Oct 16, 2020
@magento-engcom-team magento-engcom-team merged commit 1d460d1 into magento:2.4-develop Oct 21, 2020
@m2-assistant
Copy link

m2-assistant bot commented Oct 21, 2020

Hi @vestman, 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.

@ghost ghost moved this from Merge in Progress to Recently Merged in Pull Requests Dashboard Oct 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Design/Frontend Area: Frontend Auto-Tests: Covered All changes in Pull Request is covered by auto-tests Component: Checkout Component: OfflinePayments Priority: P3 May be fixed according to the position in the backlog. Progress: accept QA: Added to Regression Scope Scenario was analysed and added to Regression Testing Scope Release Line: 2.4 Risk: low Severity: S2 Major restrictions or short-term circumventions are required until a fix is available.
Projects
Pull Requests Dashboard
  
Recently Merged
Development

Successfully merging this pull request may close these issues.

Checkout: Placing an order using the enter key causes a redirect to the checkout