I think I've narrowed down the problem. The code to empty the cart is:
for cart in Cart.objects.filter(customer=order.contact):
cart.empty()
However, unless I log-in before I select an item, in my database the
customer field in the cart is null. Also, if I don't log-in at all
(i.e. if I'm not a registered user) then the customer field is always
null. This would seem to make it impossible to find the necessary
cart. Should the customer field ever be null after a purchase is
made?
Thanks,
Todd
On Aug 17, 9:54 am, twjackson <[email protected]> wrote:
> I am still trying to solve this problem and any help would be greatly
> appreciated.
>
> After a successful Paypal payment, I receive the IPN and the payment
> creates a new order. However, the shopping cart does not clear.
>
> To make matters more interesting, I have seen it clear the cart a few
> times, but only on a couple pages in the store. When I navigate to new
> pages the cart is still populated with the purchased item.
>
> I am completely new to this and confused to say the least. Could this
> have something to do with the caching? How can I force the cart to be
> cleared once I land on the checkout/success page?
>
> Thanks for you help,
>
> Todd
--
You received this message because you are subscribed to the Google Groups
"Satchmo users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/satchmo-users?hl=en.