I found 2 issues for Anonymous checkout

1. Orders without mail
Anonymous checkout - click Continue button without a selection.

2. Orders without user - i already confirmed in a previous comment
Anonymous checkout - login option selected, press continue button instead of login.

Solution - the Continue button should be disabled for both cases, it should be available only for "Continue without login" option selected.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

vasike’s picture

Status: Active » Needs review
FileSize
2.36 KB

there is a patch the implements the solution proposal from the issue description.

to achieve the issue i had to change the wrapper used for the ajax - entire checkout form to include also the buttons.

cornelia’s picture

why not simply setting the radios as required in function commerce_login_step_form_commerce_checkout_form_alter() like so
...
'#options' => array(
'anonymous' => t('Continue without login'),
'login' => t('Login with an existing account'),
),
'#required' => TRUE,
...

krisahil’s picture

We've been using this module and see the same problem. However, I'd like to propose to fix it by using the existing "Continue" button, instead of disabling it. I think this is a cleaner approach. Let me know what you think!

ultrandy89’s picture

I am finding in my site I am able to have an anonymous order with an existing email. Nothing seems to prevent this from happening. Is there even a quick rule I could put in?

To clarify:

  1. Legacy/Existing user does an anonymous checkout
  2. Said user enters in email and clicks continue
  3. No check occurs to say USER EXISTS already
Anybody’s picture

The suggestion from #2 is good and works wonderful! Please add this as a quickfix release!

The patch from #3 changes several things so that we should have a deeper look.

Is there still an active maintainer for this module willing to fix the bugs? I'd like to offer my help in maintainership if you're no more active.

PS: If we'd like to disable the process button, the Drupal form #states API will help, I think!

mglaman’s picture

Status: Needs review » Needs work

This does not prevent a user from skipping the selection of "Choose how you want to checkout"

mglaman’s picture

Status: Needs work » Needs review
FileSize
940 bytes
3.31 KB

This addresses item #1 in summary, which other patch only concerned #2. Looks like we should be solid on fix now for original issue summary.

Nebel54’s picture

+++ b/commerce_login_step.module
@@ -34,6 +34,11 @@ function commerce_login_step_form_commerce_checkout_form_alter(&$form, &$form_st
+    $existing_form_suffix = $form['#prefix'];

#prefix is used in both lines, and it raises notices, if $form['#prefix'] is not defined.

+++ b/commerce_login_step.module
@@ -135,4 +145,4 @@ function commerce_login_step_checkout_form_submit($form, &$form_state) {
\ No newline at end of file

I needed to remove this code-style improvement, to apply another patch (2362777-9)

Added an improved version of patch #7

Nebel54’s picture

Those patches went horribly wrong :( Re-Uploaded them.