Skip to content
Snippets Groups Projects
Commit a41fc73b authored by Michael Drury's avatar Michael Drury
Browse files

improved functionality of car and wishlist so that it automatically refreshes page

parent 41f4d7ae
No related branches found
No related tags found
No related merge requests found
No preview for this file type
......@@ -131,7 +131,7 @@ def cart():
total_price = get_total_cart_price()
free_shipping = False
shipping_price = 4.99
shipping_price = 14.99
if total_price >= 2000:
free_shipping = True
if free_shipping:
......@@ -172,6 +172,7 @@ def wishlist():
for c in db.session.query(User).filter_by(id=current_user.get_id()):
c.wishlist = ''
db.session.commit()
return redirect(url_for('wishlist'))
return render_template('wishlist.html', wishlist_list = wishlist_list, wishlist_size = len(wishlist_list), total_price = total_price, remove_form = remove_form)
......@@ -219,7 +220,7 @@ def checkout():
total_price = get_total_cart_price()
free_shipping = False
shipping_price = 4.99
shipping_price = 14.99
if total_price >= 2000:
free_shipping = True
if free_shipping:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment