Missing Orders

30 views
Skip to first unread message

Stephen McDonald

unread,
Jan 18, 2011, 7:26:37 PM1/18/11
to Satchmo users
Hi there,

We've an issue where occasionally the sequential ID for a ProductOrder
seems to have skipped a number. This wasn't much concern but our
client has a reconciliation report from their bank that shows a
successful transaction that references one of these skipped order IDs.

I first extracted all the records from the django_admin_log table
thinking that the only thing that could account for this would be an
admin user explicity deleting the order, however there's nothing there
indicating this happened.

Has anyone encountered a scenario like this? Is there *anywhere*
within the Satchmo code base that deletes an order? If so what are the
circumstances surrounding this?

Any help would be greatly appreciated.

Cheers,
Steve

Bruce Kroeze

unread,
Jan 18, 2011, 11:22:02 PM1/18/11
to satchm...@googlegroups.com
Because Django works this way, it *is* possible to delete from the admin things that would cause deletion of an order.

For example, if an admin deleted a product, and that product was a member of an order, it would delete the order.

That's why we have the active/inactive flag.  You should never delete a product.


--
You received this message because you are subscribed to the Google Groups "Satchmo users" group.
To post to this group, send email to satchm...@googlegroups.com.
To unsubscribe from this group, send email to satchmo-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/satchmo-users?hl=en.




--
Bruce Kroeze
http://www.ecomsmith.com
It's time to hammer your site into shape.

Stephen McDonald

unread,
Jan 19, 2011, 1:31:02 AM1/19/11
to Satchmo users
Would deleting a product simply not remove it from the order?


On Jan 19, 3:22 pm, Bruce Kroeze <bkro...@gmail.com> wrote:
> Because Django works this way, it *is* possible to delete from the admin
> things that would cause deletion of an order.
>
> For example, if an admin deleted a product, and that product was a member of
> an order, it would delete the order.
>
> That's why we have the active/inactive flag.  You should never delete a
> product.
>
> On Tue, Jan 18, 2011 at 4:26 PM, Stephen McDonald <stephen...@gmail.com>wrote:
>
>
>
>
>
>
>
>
>
> > Hi there,
>
> > We've an issue where occasionally the sequential ID for a ProductOrder
> > seems to have skipped a number. This wasn't much concern but our
> > client has a reconciliation report from their bank that shows a
> > successful transaction that references one of these skipped order IDs.
>
> > I first extracted all the records from the django_admin_log table
> > thinking that the only thing that could account for this would be an
> > admin user explicity deleting the order, however there's nothing there
> > indicating this happened.
>
> > Has anyone encountered a scenario like this? Is there *anywhere*
> > within the Satchmo code base that deletes an order? If so what are the
> > circumstances surrounding this?
>
> > Any help would be greatly appreciated.
>
> > Cheers,
> > Steve
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Satchmo users" group.
> > To post to this group, send email to satchm...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > satchmo-user...@googlegroups.com<satchmo-users%2Bunsubscribe@goog legroups.com>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/satchmo-users?hl=en.
>
> --
> Bruce Kroezehttp://www.ecomsmith.com

hynekcer

unread,
Jan 19, 2011, 3:45:03 PM1/19/11
to Satchmo users
On 19 led, 07:31, Stephen McDonald <stephen...@gmail.com> wrote:
> Would deleting a product simply not remove it from the order?

Yes, the mystery. Deleting of Order Line Item is required by reference
integrity, not whole order.

It seems that only deleting of contact (or site) should cause deleting
of order due to reference integrity.

Hmm. It is easily verified that neither paying customer's contact nor
whole site record was deleted. :-)

Have not you a message "Deleting incomplete order #... from database"
in the log.info?
(I only made "grep -irC5 order.*delete .")

Stephen McDonald

unread,
Jan 19, 2011, 4:51:06 PM1/19/11
to Satchmo users
Thanks hynecker.

I hadn't considered the Contact model, but again I've gone through the
admin_log history and no contacts or sites have been deleted.

Nothing shows in the log either unfortunately.

Rob Speed

unread,
May 2, 2013, 3:01:39 PM5/2/13
to satchm...@googlegroups.com
I launched my first site using satchmo yesterday and encountered this same issue. This thread is is over two years old, but since this issue is still present and (as far as I can tell) unexplained, I thought it would be worth adding my thoughts. After a bit of sleuthing I think I've come up with the reason this happens.

As soon as a customer submits the form on the first page of the checkout process, an order record is created. If that customer then leaves the checkout process and modifies the contents of their cart in any way, that incomplete order record is deleted. Simple as that.

The fix would be to patch Satchmo to keep order information in the session, and only create the record when checkout process is completed.
Reply all
Reply to author
Forward
0 new messages