{% load quantity %}
{% load item_views %}
<form action="/basket/" method="post">
	<input type="hidden" name="next" value="{{request.path}}" />
	<table class="basket">
		<tr>
			<th>Item</th>
			<th>Qty</th>
			<th>Price</th>
			<th>&nbsp;</th>
		</tr>
		{% for i in basket %}
		<tr>
			<td>{% item_view view-basket-item i %}</td>
			<td>{% quantity i %}</td>
			<td>£{{i.get_total_price|floatformat:2}}</td>
			<td><input type="image" src="/assets/images/but_remove.png" alt="Remove" name="remove-item-{{i.list_id}}"/></td>
		</tr>
		{% endfor %}
		{% if basket.charges %}
		<tr class="total">
			<th colspan="2">Subtotal</th>
			<td>£{{basket.get_subtotal|floatformat:2}}</td>
			<td>&nbsp;</td>
		</tr>
		{% for charge, value in basket.get_charges %}
		<tr class="total">
			<th colspan="2">{{charge}}</th>
			<td>£{{value|floatformat:2}}</td>
			<td>&nbsp;</td>
		</tr>
		{% endfor %}
		{% endif %}
		<tr class="total">
			<th colspan="2">Total</th>
			<td>£{{basket.get_total|floatformat:2}}</td>
			<td>&nbsp;</td>
		</tr>
	</table>
<p class="buttons"><input type="image" src="/assets/images/but_update_basket.png" alt="Update basket" /> <a href="/checkout/"><img src="/assets/images/but_continue_checkout.png" alt="Continue to Checkout" /></a></p>
</form>

