{% load thumbnail %}

{% if buyables %}
	<table class="itemList">
		<tbody>
		{% for buyable in buyables %}
			<tr>
				<td class="productImage">
					<a href="/store/show/{{ buyable.id }}"><img src="{% thumbnail buyable.image 64x64 %}"/></a>
				</td>
				<td class="name"><a href="/store/show/{{ buyable.id }}">{{ buyable.name }}</a></td>
				<td class="actions">
					{% if buyable.hasDeposit %}
						<a class="button buy" href="/store/buy/{{ buyable.id }}"
							title="Kaufen (Ohne Pfand)">
							<span><span>{{ buyable.price|floatformat:2 }}€</span></span>
						</a>

						<a class="button buy inclDeposit"
							href="/store/buy/{{ buyable.id }}/with/deposit"	title="Kaufen (Mit Pfand)">
							<span><span>{{ buyable.price|floatformat:2 }}€ / {{ buyable.deposit|floatformat:2 }}€</span></span>
						</a>

						<a class="button buy onlyDeposit" 
							href="/store/buy/{{ buyable.id }}/only/deposit"	title="Kaufen (Nur Pfand)">
							<span><span>{{ buyable.deposit|floatformat:2 }}€</span></span>
						</a>

					{% else %}
						<a class="button buy" href="/store/buy/{{ buyable.id }}"
							title="Kaufen">
							<span><span>{{ buyable.price|floatformat:2 }}€</span></span>
						</a>
					{% endif %}
				</td>
			</tr>
		{% endfor %}
		</tbody>
	</table>
{% else %}
	<p>{{ default|default_if_none:"Noch keine gekauft" }}</p>
{% endif %}
