Page 1 of 1

The incomplete order #XXXX was deleted automatically (custom

Posted: Mon Jul 05, 2010 7:50 am
by myshop
I thought that 5.5.4 was supposed to show and keep incomplete orders?

Throughout the logs I find entries like this:

The incomplete order #XXXX was deleted automatically (customer began new checkout).

Sure enough, the order is completely missing from the all orders and incomplete orders sections. Can someone advise why its doing this when the system is supposed to keep incomplete orders?

Re: The incomplete order #XXXX was deleted automatically (custom

Posted: Mon Jul 05, 2010 1:19 pm
by grantg
Incomplete orders are stored depending on the length of time you have set in the settings (one day, week, month, 3 months)

An Incomplete order is generated between the customer clicking 'Pay Now' and the end check-out page - ie. after confirming their order details, selecting shipping method, selecting payment method and then clicking the continue button to complete the payment stage - if the customer does not complete the payment successfully, an Incomplete order is generated.

This will be wiped from the system if the customer then goes back to the check-out (ie. yourdomain.com/checkout.php is reloaded).

Re: The incomplete order #XXXX was deleted automatically (custom

Posted: Tue Jul 06, 2010 7:13 am
by myshop
Hi Grantg
This will be wiped from the system if the customer then goes back to the check-out (ie. yourdomain.com/checkout.php is reloaded).
Well that is crazy!

My client uses MIGS gateway and he can login to that system and view all attempts - There are dozends of failed attempts all with their own cart generated order numbers. These are simply missing from the cart database - they are not in ALL ORDERS or INCOMPLETE.

The whole idea of the system keeping incomplete orders is so that we can see them - But if it deletes the incomplete order when the customer goes to checkout.php then whats the point of keeping them in the first place?

Senario:

Customer adds products to the cart - proceeds to checkout, adds their details, attempts a credit card transaction - It fails.
At this point we should be able to see the incomplete order in the cart database.
They then go back and add more products to the cart - Proceed to the checkout again (which takes them to checkout.php)
The incomplete order is deleted (if what you say is correct)
The customer bows out all together.

We have now completely lost any record of the incomplete order?!!

Crazy.

Fix: Show "Deleted" orders that were abandoned

Posted: Fri May 31, 2013 1:18 am
by Martin
Quick fix to the "Deleted order" functionality in 6.1.1 (probably applies to newer versions too).

The orders are being saved in the database but not being shown in the "Deleted orders" view so you just need to make the following change:

Open: /admin/includes/classes/class.orders.php

Find:

Code: Select all

			// Otherwise, only fetch complete orders
			else {
				$queryWhere .= " AND ordstatus > 0";
			}
Replace with:

Code: Select all

			// Otherwise, only fetch complete orders
			else {
//MOD Show orders dropped when customer started new cart
				if(!$searchDeletedOrders) {
					$queryWhere .= " AND ordstatus > 0";
				}
				//$queryWhere .= " AND ordstatus > 0";
//MOD END
			}
... and you will then find you can see those orders that somehow got lost when the customer started a new checkout or similar... Obviously you need to make sure your settings don't just purge everything but this appears to work just fine...



EDIT:
Worth noting that I realised that it allows you to see ALL of the orders that supposedly had been deleted. Bit strange that Interspire never provided a function to purge these properly as I'm sure it must be clogging up some stores databases but in this instance, very useful data has been revealed! :)