Orders not showing up

  • Posts: 303
  • Thank you received: 18
7 years 10 months ago #260290

-- url of the page with the problem -- : www.mojooutdoors.com
-- HikaShop version -- : 2.6.3
-- Joomla version -- : 3.6.3
-- PHP version -- : 5.6

Over the last few days, we are showing credit card charges from the website through our First data account. However, there is no record on the hikashop backend and no record inside the payment log. I even checked the error log of the website but nothing out of the ordinary.

This has become a problem as customers are being charged and we have no idea what (or if) they ordered.

Any ideas on what's going on?

Please Log in or Create an account to join the conversation.

  • Posts: 82867
  • Thank you received: 13373
  • MODERATOR
7 years 10 months ago #260328

Hi,

If you're using the FirstData payment plugin (which displays the credit card form directly in the HikaShop checkout), then the payment is process just before the order is created.
So there two ways in which this could happen:

- there is a MySQL error when the order is created because some column is missing in the hikashop_order table. But it's likely that this would happen for all the orders then and pressing the "check database" button of the HikaShop configuration would likely fix the problem.

- there is a plugin triggered between the payment plugin and the MySQL query to create the order which cancels the creation of the order. It's going to be hard to track if it's coming from that. You would have to reproduce the problem and disable the plugins one by one to identify the one causing the issue.
An easier solution you could try but which mgith not change anything is to change the ordering of the FirstData plugin to something like 9999 in order to be the last plugin to be triggered so that no other plugin can cancel the order creation after the payment plugin.

Please Log in or Create an account to join the conversation.

  • Posts: 303
  • Thank you received: 18
7 years 10 months ago #260373

Why wouldn't the payment plugin be processed AFTER the order is created? Seems like it would be safer that way?

I checked in the database and changed the ordering of the First Data Plugin to be further down (would not allow me to put at the end of the plugin list?)

It's just very strange. Wouldn't the payment be logged in the payment log file even if the order wasn't created? i figured the payment log would be absolute.

Any there any other possibilities? This could result in a major financial problem down the road if customers aren't getting their orders but still get charged.

Please Log in or Create an account to join the conversation.

  • Posts: 82867
  • Thank you received: 13373
  • MODERATOR
7 years 9 months ago #260380

Hi,

It was done like that because normally this never happens and thus avoids the creation of orders which will never be confirmed (when the credit card is refused for example).
You're the first one reporting an issue which could potentially come from that.

As all the processing happens on the page with FirstData, when the debug mode is turned on the debug data is displayed directly on the screen and not in the payment log file. The payment log file is used for payment methods where the only way you can get to see the data sent back by the server is to store it in a file to be able to read it.
So it's normal that you don't read anything in the payment log for Firstdata.

I don't see any other way this could happen unless you were receiving payments from somewhere else than HikaShop (and thus it's normal that it wouldn't store an order in HikaShop).

Try to change the line:
function onBeforeOrderCreate(&$order, &$do) {
to:
function onAfterOrderCreate(&$order) {
in the file plugins/hikashoppayment/firstdata/firstdata.php
That way, orders will be created regardless of whether the payment is valid or not and only the orders with the payment valid will have their status changed to "confirmed" (allowing you to distinguish ones from the others).
And that will prevent a payment to happen and the corresponding order to be created if another plugin cancels it. In that case, the order won't be created and the payment won't be processed.

Please Log in or Create an account to join the conversation.

Time to create page: 0.057 seconds
Powered by Kunena Forum