Open GannTrader opened 3 years ago
I will update it tomorrow.Thanks
Hi!
This would be a great feature, yet it is still not there.
hello @MahmudulHassan5809 could you please kindly add that small feature where i can get the total amount of all products
Edit this this in veiws.py
@login_required(login_url="/users/login") def cart_detail(request): total_amt = 0 for id,item in request.session['cart'].items(): total_amt+= int(item['quantity'])*float(item['price']) return render(request, 'cart_detail.html', {'total': total_amt})
it is available, with the context preprocessor, you can just use Total price € {{ cart_total_amount|floatformat:2 }}
in your template
hi i want to know how i can total amount of all products?