Hi zmove,

I'm having some orders registered as anonymous user i.e. $user->uid == 0.

It was working great until I upgraded from uc_atos first release on Ubercart.org to now using the version called 1.2.1.

There's a lot of code changes between those two versions, so it's kind of hard to debug things.

After a lot of testing, I'm pretty sure this only happens with new customers (and maybe old ones), that do not come back to the store after having filled their payment info. They do not click on "Retour à la boutique".

Do you have any clue on this?

Thank you so much!
Jérémy

Comments

jchatard’s picture

I think I just found it !

/**
 * Autoresponse callback
 */
function uc_atos_autoresponse() {
  if (isset($_POST['DATA'])) {
    _uc_atos_complete_order(TRUE);
  }

  exit; //Don't launch all the theme thing for this (hope it doesn't break anything :)
}

This is the exit statment that breaks all!

Because, it stops, but it should let Ubercart call all the function like uc_cart_checkout_complete() which calls uc_cart_complete_sale() which is in charge of creating the new user!

Don't you think?

zmove’s picture

Status: Active » Needs review

Thank you for your feedback and your suggestion, I will try that and commit if it's the great fix !

jchatard’s picture

Hi zmove,

I tried, but the problem is more tricky!

Let's say, you just leave the exit statment, then the autoresponse will be in charge of terminating the order (creating the new account if needed, sending emails, dicreasing the stock, etc.).

This is great, but :

  • if the user doesn't come back, you loose your Google Analytics e-commerce stats (and I really don't see any way of solving this), because I don't think Atos autoresponse is interpreting JS.
  • if the user actually click on "Retour à la boutique", then the uc_cart_complete_sale() function is called one more time, which is really really bad, it decreases the stock, it sends email one more time (I think), etc. etc.

In fact, I really don't see any solution, apart from forcing the user to come back to the site, but how?

Jérémy

zmove’s picture

Hmmm, I remember I had lots of problems with google analytics integration cause lots of people don't clock on "retour a la boutique" button. The only solution would be to ask to ATOS if it's possible to directly return to our shop url after a successfull payment.

It was on my todo list long time ago, but lots of project came between, and I never had time to take this task.

So, I let the release as it is, waiting (and searching too, a little ^^) for another solution.

I didn't let anonymous user order on my shop because of this issue...

jchatard’s picture

Ok,

Maybe you could put this issue in a README file and/or on the project page, because it's really an anoying problem!

Thanks,
Jérémy

zmove’s picture

Status: Needs review » Active

I updated the module description to notice that problem.

zmove’s picture

Priority: Critical » Normal

Changed the priority cause it affect only anonymous order. I prefer to keep critical issue for fatal error problems.

modjodandy’s picture

Does any of you guys found a good fix for this module?

anrikun’s picture

Version: 5.x-1.x-dev » 6.x-1.x-dev
Status: Active » Fixed

It is now fixed in the last 6.x-1.x dev version.
Please review it.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.