<!-- content_cash_desk/shoppingcart.tpl -->
<div class="full_box">
	<div class="title_wrapper">
		<div class="title"><h2>Warenkorb</h2></div>
		<div class="clear"></div>
	</div>

	<div class="box_content">
		<div class="box_padder">
			{if $shoppingcart.items}
				<table class="cart_table" width="100%" border="0" cellpadding="0" cellspacing="0">
					<tr class="cart_head">
						<td class="alcenter">Pos.</td>
						<td class="alcenter">Bild</td>
						<td>Beschreibung</td>
						<td class="alright">St&uuml;ckpreis</td>
						<td class="alcenter">Anzahl</td>
						<td class="alright">Gesamtpreis</td>
					</tr>

					{foreach item=item name=carLoop from=$shoppingcart.items}
						<tr class="cart_row">
							<td class="alcenter">{$smarty.foreach.carLoop.iteration}</td>
							<td class="alcenter"><img src="{$SHOP_DIR}images/article/thumb_{if $item->default_image_file_name}{$item->default_image_file_name}{else}default_image.png{/if}" /></td>
							<td>
							{if $item->short_uri}
								{assign var=itemSuri value="/`$item->short_uri`.html"}
							{else}
								{assign var=itemSuri value="/index.php?item_id=`$item->id`"}
							{/if}
							<a href="{$serverProtocol}://{$servername}{$itemSuri}"><strong>{$item->name}</strong></a><br />
							{if (isset($item->cartVariant_1) && $item->cartVariant_1) || (isset($item->cartVariant_2) && $item->cartVariant_2)}
								{if isset($item->cartVariant_1)}{$item->cartVariant_1}{/if} {if isset($item->cartVariant_2)}{$item->cartVariant_2}{/if}<br />
							{/if}
							{if ($item->variant_1 || $item->variant_2) && $item->item_number}
								<span>Art.-Nr. {$item->item_number}</span>
							{else}
								{if $item->attribute_7 && $item->number != $item->attribute_7}
									<span>Art.-Nr. {$item->attribute_7}&nbsp;&nbsp;&nbsp;({$template_text.item_details.old_item_number_title} {$item->number})</span>
								{else}
									<span>Art.-Nr. {$item->number}</span>
								{/if}
							{/if}
							</td>
							<td class="alright">{$item->calculatedPrices.shownPrice|number_format:"2":",":"."} &euro;</td>
							<td class="alcenter">
								{$item->quantity}
							</td>
							<td class="alright">
								<strong>{($item->calculatedPrices.shownPrice * $item->quantity)|number_format:"2":",":"."} &euro;</strong>
							</td>
						</tr>
					{/foreach}

					<tr class="cart_footer_first">
						<td></td>
						<td>&nbsp;</td>
						<td>Summe aller Artikel</td>
						<td></td>
						<td></td>
						<td class="alright">{$shoppingcart.shown_price_sum|number_format:"2":",":"."} &euro;</td>
					</tr>

					{if $personal_data.payment_method}
						{assign var=usedPaymentMethod value=$payment_methods[$personal_data.payment_method]}
					{else}
						{assign var=usedPaymentMethod value=$payment_methods[$defaultPaymentMethod]}
					{/if}
					{if $usedPaymentMethod->paymentAddShown != 0}
						<tr class="alright">
							<td></td>
							<td>&nbsp;</td>
							<td>
								{if $usedPaymentMethod->accountType == '0'}
									zzgl. Dienstleistungsgeb&uuml;hren
								{elseif $usedPaymentMethod->accountType == '1'}
									abzgl. Dienstleistungsgeb&uuml;hren
								{elseif $usedPaymentMethod->accountType == '2'}
									zzgl. Dienstleistungsgeb&uuml;hren
								{elseif $usedPaymentMethod->accountType == '3'}
									abzgl. Dienstleistungsgeb&uuml;hren
								{/if}
							</td>
							<td></td>
							<td></td>
							<td class="alright">
								{$usedPaymentMethod->paymentAddShown|number_format:"2":",":"."} &euro;
							</td>
						</tr>
					{/if}

					{if $personal_data.shipping_method}
						{assign var=usedShippingMethod value=$deliverers[$personal_data.shipping_method]}
					{else}
						{assign var=usedShippingMethod value=$deliverers[$defaultDeliverer]}
					{/if}
					{if $usedShippingMethod->price_add_shown != 0}
						<tr class="alright">
							<td></td>
							<td>&nbsp;</td>
							<td>zzgl. Versandkostenpauschale</td>
							<td></td>
							<td></td>
							<td class="alright">
								{$usedShippingMethod->price_add_shown|number_format:"2":",":"."} &euro;
							</td>
						</tr>
					{/if}

					{foreach $shoppingcart.tax_values as $taxRate => $taxData}
						<tr class="cart_footer_vat">
							<td></td>
							<td>&nbsp;</td>
							<td>
								{if $shoppingcartVATUsage}
									Darin enthaltene MwSt.
								{else}
									Zzgl. MwSt.
								{/if}
							</td>
							<td>{$taxRate} %</td>
							<td></td>
							<td class="alright">
								{if $taxRate == '19.00'}
									{($taxData['vat'] + $shoppingcart.payment_method_vat + $shoppingcart.shipping_method_vat)|number_format:"2":",":"."}
								{else}
									{$taxData['vat']|number_format:"2":",":"."}
								{/if}
								&euro;
							</td>
						</tr>
					{/foreach}

					{if isset($giftcertificatevalue) && $giftcertificatevalue}
						<tr class="cart_footer_sum">
							<td></td>
							<td>&nbsp;</td>
							<td>
								Zwischen Betrag
							</td>
							<td></td>
							<td></td>
							<td class="alright">
								{$shoppingcart.order_total|number_format:"2":",":"."} &euro;
							</td>
						</tr>

						<tr class="alright">
							<input type="hidden" name="giftcertificate[has_gift_certificate]" value="yes" />
							<input type="hidden" name="giftcertificate[gift_certificat_code]" value="{$giftcode}" />
							<td></td>
							<td>&nbsp;</td>
							<td>abzgl. Gutschein {$giftcode}</td>
							<td></td>
							<td></td>
							<td class="alright">
								- {$giftcertificatevalue|default:0|number_format:"2":",":"."} &euro;
							</td>
						</tr>
							{*
							{foreach $shoppingcart.tax_values as $taxRate => $taxData}
							<tr class="cart_footer_vat">
								<td></td>
								<td>
									{$taxData['gift']['percent']|number_format:"2":",":"."} % davon mit {$taxRate} % MwSt.
								</td>
								<td></td>
								<td></td>
								<td class="alright">
									<!-- what do you want to show in an order that is without taxes -->
								</td>
							</tr>
							{/foreach}
							*}
						<tr class="cart_footer_sum">
							<td></td>
							<td>&nbsp;</td>
							<td>
								Gesamtpreis inkl. Mwst.
							</td>
							<td></td>
							<td></td>
							<td class="alright">
								{($shoppingcart.order_total - ($giftcertificatevalue|default:0))|number_format:"2":",":"."} &euro;
							</td>
						</tr>
					{else}
						<tr class="cart_footer_sum">
							<td></td>
							<td>&nbsp;</td>
							<td>
								Gesamtpreis inkl. Mwst.
							</td>
							<td></td>
							<td></td>
							<td class="alright">
								{$shoppingcart.order_total|number_format:"2":",":"."} &euro;
							</td>
						</tr>
						{if $system_configuration.cashdesk_giftcertificate == 1}
							<tr>
								<td></td>
								<td>&nbsp;</td>
								<td style="text-align:right;">
									{if $gftcertificateerrormessage}
										<label style="color:red;">{$gftcertificateerrormessage}</label>
									{else}
										<label>Gutschein</label>
									{/if}
									<input type="hidden" name="giftcertificate[has_gift_certificate]" id="has_gift_certificate" {if $giftcode}value="yes"{/if} />
									<input type="text" class="obligatory" name="giftcertificate[gift_certificat_code]" id="giftCertificateCodeFields" style="width:155px;color:#5C0069;background:#D4D4D4;border:1px solid #A8A8A8;" {if $giftcode}value="{$giftcode}"{/if} />
								</td>
								<td></td>
								<td></td>
								<td></td>
							</tr>
						{/if}
					{/if}

				</table>
				<br /><br />

				<div style="float:right;padding-right:0px;">
					<input class="button" id="send_order_button" type="button" style="width:300px;" value="{$template_text.content_cashdesk.cashdesk_button}" />
				</div>
				<br style="clear:right;" />

	
			{else}
				Es befinden sich keine Artikel in Ihrem Warenkorb
			{/if}
		</div>
	</div>
</div>