Skip to content

Instantly share code, notes, and snippets.

View joshcartme's full-sized avatar

Josh Cartmell joshcartme

View GitHub Profile
@joshcartme
joshcartme / gist:3943826
Created October 24, 2012 04:26
cartridge order setup which adds in tax total
def custom_order_setup(self, request):
"""
Set order fields that are stored in the session, item_total
and total based on the given cart, and copy the cart items
to the order. Called in the final step of the checkout process
prior to the payment handler being called.
Adds tax to the order total.
"""
self.key = request.session.session_key
self.user_id = request.user.id