<{if $subject}>

	<{t section="Mail" order_id=$order->getWebshopOrderId() webshop_name=$webshop->getName()}>Din ordre {order_id} fra {webshop_name} er afsendt<{/t}>

<{else}>

	<html>

	<head>
		<title>Din ordre er sendt</title>
		<style type="text/css">
			html, body {
				background:#f2f2f2;
				font-family:helvetica, sans-serif;
				margin:0px;
				padding:0px;
			}

			#main {
				margin:50px;
				padding:20px;
				background:#fff;
			}

			fieldset {
				border:1px solid #eee;
				margin: 20px 0px 20px 0px;
			}

			fieldset legend {
				font-weight:bold;
			}

			a {
				color:#00a;
				text-decoration:none;
			}

			.product {
				margin-bottom:20px;
			}

			.product .img {
				width:70px;
				float:left;
			}

			.product .inner-product {
				padding:0px 0px 0px 0px;
				float:left;
			}
		</style>
	</head>

	<body>

		<div id="main">

			<{if $logo = $webshop->getLogo()}>
				<h1><a href="/"><img src="<{$logo->getInline(100, 100, 'fit')}>" alt="<{$webshop->getName()|escape}>" /></a></h1>
			<{else}>
				<h1><a href="/"><{$webshop->getName()|escape}></a></h1>
			<{/if}>

			<h1><{t section="Mail"}>Din ordre er afsendt<{/t}></h1>

			<p><strong><{t section="Mail"}>Hej<{/t}> <{$order->getOrderFirstName()|escape}></strong></p>

			<p><{t section="Mail"}>Vi har nu færdigbehandlet og afsendt din ordre.<{/t}></p>

			<{if $order->getPickupAddress()}>
				<fieldset>
					<legend><{t section="Mail"}>Pakkeshop<{/t}></legend>
					<{$order->getPickupAddress()|escape|nl2br}>
				</fieldset>
			<{/if}>

			<{if $order->getTrackingNumbers()}>
				<p>
					<{assign var="shipping" value=$order->getShipping()}>
					<{assign var="tracking_numbers" value=$order->getTrackingNumbers()}>

					<strong><{t section="Mail"}>Følg din ordre hos<{/t}> <{$shipping->getName()|escape}>:</strong>

					<{section name="k" loop=$tracking_numbers}>
						<{if $shipping && $shipping->getTrackingUrl()}>
							<a href="<{$shipping->getTrackingUrl($tracking_numbers[k])|escape}>" target="_blank"><{$tracking_numbers[k]|escape}></a><{if !$smarty.section.k.last}>,<{/if}>
						<{else}>
							<{$tracking_numbers[k]|escape}><{if !$smarty.section.k.last}>,<{/if}>
						<{/if}>
					<{/section}>
				</p>
			<{/if}>

			<h3><{t section="Mail"}>Dine varer<{/t}></h3>

			<{assign var="products" value=$order->getProducts()}>
			<{section name="i" loop=$products}>
				<div class="product">
					<div class="img">
						<{assign var="image" value=$products[i]->getImage()}>
						<{if $image}>
							<a href="<{$products[i]->getRemoteUrl()|escape}>" target="_blank"><img src="<{$image->getInline(60, 60, 'box')}>" style="border-radius:5px; float:left;"></a>
						<{/if}>
					</div>

					<div class="inner-product">
						<div><strong><{$products[i]->getAmount()}> stk. <a href="<{$products[i]->getRemoteUrl()|escape}>" target="_blank"><{$products[i]->getName()|escape}></a></strong></div>

						<{assign var="attributes" value=$products[i]->getAttributes()}>
						<{if $attributes}>
							<{section name="j" loop=$attributes}>
								<div style="font-size:0.9em;"><{$attributes[j].name}>: <{$attributes[j].val}></div>
							<{/section}>
						<{/if}>

					</div>

					<div style="clear:both;"></div>
				</div>
			<{/section}>

			<p>
				<strong><{t section="Mail"}>Pris:<{/t}></strong> <{$order->getPrice()|number_format:2:",":"."}> <{$webshop->getCurrency()}><br>
				<small><{t section="Mail"}>Heraf moms:<{/t}> <{$order->getVat()|number_format:2:",":"."}> <{$webshop->getCurrency()}></small>
			</p>

			<p><strong><{t section="Mail"}>Fragt:<{/t}></strong> <{$order->getShippingPrice()|number_format:2:",":"."}> <{$webshop->getCurrency()}></p>

			<{assign var="voucher" value=$order->getVoucher()}>
			<{if $voucher}>
				<p><strong><{t section="Mail"}>Gavekort:<{/t}></strong> <{$voucher->getCode()|escape}></p>
			<{/if}>

			<{assign var="shipping" value=$order->getShipping()}>
			<{if $shipping}>
				<p><strong><{t section="Mail"}>Leveringsmetode:<{/t}></strong> <{$shipping->getName()|escape}></p>
			<{/if}>

			<p><strong><{t section="Mail"}>E-mail-adresse:<{/t}></strong> <{$order->getEmail()|escape}></p>
			<p><strong><{t section="Mail"}>Telefonnummer:<{/t}></strong> <{$order->getPhone()|escape}></p>

			<fieldset>
				<legend><{t section="Mail"}>Bestillingsadresse<{/t}></legend>
				<p>
					<{$order->getOrderName()|escape}><br>
					<{if $order->getOrderCompanyName()}>
						<{$order->getOrderCompanyName()|escape}><br>
					<{/if}>
					<{if $order->getVatNumber()}>
						<{t section="Mail"}>CVR-nummer:<{/t}> <{$order->getVatNumber()|escape}><br>
					<{/if}>
					<{$order->getOrderAddress()|escape}><br>
					<{$order->getOrderZipcode()|escape}> <{$order->getOrderCity()|escape}><br>
					<{$order->getOrderCountry()|escape}>
				</p>
			</fieldset>

			<fieldset>
				<legend><{t section="Mail"}>Leveringsadresse<{/t}></legend>
				<p>
					<{$order->getDelName()|escape}><br>
					<{if $order->getDelCompanyName()}>
						<{$order->getDelCompanyName()|escape}><br>
					<{/if}>
					<{$order->getDelAddress()|escape}><br>
					<{$order->getDelZipcode()|escape}> <{$order->getDelCity()|escape}><br>
					<{$order->getDelCountry()|escape}>
				</p>
			</fieldset>

			<p><{t section="Mail" url=$order->getPublicUrl()|escape}>Se også din ordre på <a href="{url}">{url}</a><{/t}></p>


		</div>

	</body>

	</html>

<{/if}>