241 lines
10 KiB
Smarty
241 lines
10 KiB
Smarty
{extends "index.tpl"}
|
|
|
|
{block "css-entry" append}
|
|
{ifmodule WEBPACK}
|
|
{encore_entry_link_tags entry='cart'}
|
|
{/ifmodule}
|
|
{/block}
|
|
|
|
{block "meta-robots"}
|
|
<meta name="robots" content="noindex, nofollow">
|
|
{/block}
|
|
|
|
{block content}
|
|
{change_currency currency=$body.order->currency}
|
|
<div class="page-orderview">
|
|
<h1>{t}Objednávka{/t}{if $body.order.order_no}: {$body.order.order_no}{/if}</h1>
|
|
|
|
{include "block.messages.tpl"}
|
|
|
|
{if $body.error != ''}
|
|
<div class="alert alert-info" role="alert">
|
|
{$body.error nofilter}
|
|
</div>
|
|
{/if}
|
|
|
|
{if $body.payment && $body.payment->hasOnlinePayment() && $body.order->isActive() && !$body.order->isPaid()}
|
|
{$body.payment->getOrderViewDescription() nofilter}
|
|
{/if}
|
|
|
|
<p class="order-date">{t}Datum objednání{/t}:
|
|
<strong>{$body.order.date_created|date_format:"%d.%m.%Y %H:%M:%S"}</strong></p>
|
|
|
|
<p class="order-status">{t}Aktuální stav objednávky{/t}: <strong>
|
|
{if $body.order.status_storno}
|
|
{t}Objednávka stornována{/t}
|
|
{else}
|
|
{$body.order.status_text}
|
|
{/if}</strong>
|
|
</p>
|
|
|
|
{block "history"}
|
|
<p class="order-history"><a href="" data-opener="#order-history">{t}Zobrazit historii objednávky{/t} <i
|
|
class="fc icons_arrow_down"></i></a></p>
|
|
<div id="order-history" style="display:none" class="opener-content">
|
|
<table class="table">
|
|
<tr>
|
|
<th>{t}Datum{/t}</th>
|
|
<th>{t}Stav{/t}</th>
|
|
</tr>
|
|
{foreach $body.order->getHistory() as $history}
|
|
<tr>
|
|
<td>{$history.date|date_format:"%d.%m.%Y %H:%M:%S"}</td>
|
|
<td>{$history.status_text}</td>
|
|
</tr>
|
|
{/foreach}
|
|
</table>
|
|
</div>
|
|
{/block}
|
|
|
|
<hr>
|
|
|
|
{block "address"}
|
|
<div class="row">
|
|
<div class="col-md-4 col-lg-4">
|
|
<h3 class="form-title">{t}Kontaktní údaje{/t}</h3>
|
|
<ul class="summary-list">
|
|
<li><strong>{$body.order.invoice_name} {$body.order.invoice_surname}</strong></li>
|
|
{if $body.order.invoice_firm}
|
|
<li>{$body.order.invoice_firm}</li>
|
|
{/if}
|
|
<li>{$body.order.invoice_email}</li>
|
|
<li>{$body.order.invoice_phone}</li>
|
|
</ul>
|
|
</div>
|
|
|
|
{if $body.order.invoice_street or $body.order.invoice_city or $body.order.invoice_zip}
|
|
<div class="col-md-4 col-lg-4">
|
|
<h3 class="form-title"> </h3>
|
|
<ul class="summary-list">
|
|
<li>{$body.order.invoice_street}</li>
|
|
<li>{$body.order.invoice_city}</li>
|
|
<li>{$body.order.invoice_zip}</li>
|
|
|
|
<li>{$cfg.Order.Countries[$body.order.invoice_country]}</li>
|
|
</ul>
|
|
</div>
|
|
{/if}
|
|
</div>
|
|
<hr>
|
|
{/block}
|
|
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<h3>{t}Doprava a platba{/t}</h3>
|
|
|
|
<ul class="summary-list">
|
|
{$deliveryType = $body.order->getDeliveryType()}
|
|
<li>{$deliveryType.delivery}
|
|
{if !empty($deliveryType.delivery_class->psc)}
|
|
({$deliveryType.delivery_class->psc})
|
|
{/if}
|
|
- {$deliveryType.payment}
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<hr>
|
|
|
|
{if $body.order.note_user}
|
|
<h2>{t}Poznámka k objednávce{/t}</h2>
|
|
<p>{$body.order.note_user|escape:'htmlall'|nl2br nofilter}</p>
|
|
<hr>
|
|
{/if}
|
|
|
|
{if $body.order.noteAdmin}
|
|
<h2>{t}Poznámka pro zákazníka{/t}</h2>
|
|
<p>{$body.order.noteAdmin}</p>
|
|
<hr>
|
|
{/if}
|
|
|
|
{block "products"}
|
|
<h2>{t}Objednané zboží{/t}</h2>
|
|
<div class="table-cart">
|
|
{foreach $body.order.items as $product}
|
|
<div class="product">
|
|
<div class="product-inner display-table" data-cart="row">
|
|
<div class="col-xs-1 product-image text-center">
|
|
{if $product.id_product}
|
|
<a title="{t}Zobrazit zboží{/t}"
|
|
href="{url s=product IDproduct=$product.id_product TITLE=$product.descr}">
|
|
<img src="{get_photo id=$product.photo|default:0 image=2}" alt="{$product.descr}"
|
|
class="img-responsive">
|
|
</a>
|
|
{else}
|
|
<img src="{get_photo id=$product.photo|default:0 image=2}" alt=""
|
|
class="img-responsive">
|
|
{/if}
|
|
</div>
|
|
<div class="col-xs-7 product-title">
|
|
{if $product.id_product}
|
|
<a title="{t}Zobrazit zboží{/t}"
|
|
href="{url s=product IDproduct=$product.id_product TITLE=$product.descr}">{$product.descr}</a>
|
|
{else}
|
|
{$product.descr}
|
|
{/if}
|
|
|
|
{if $product.product and $product.note}
|
|
{block "product-notes"}
|
|
{$itemInfo = $body.order->getItemInfo($product)}
|
|
{foreach $itemInfo as $key => $print_note}
|
|
<div class="small">{$print_note nofilter}</div>
|
|
{/foreach}
|
|
{/block}
|
|
{/if}
|
|
|
|
{$cf = $body.order->getSecurityCode()}
|
|
{get_order_coupons order=$body.order assign='order_coupons'}
|
|
{if !empty($order_coupons[$product.id])}
|
|
<br>
|
|
{t}Kód{/t}:
|
|
{foreach $order_coupons[$product.id] as $coupon}
|
|
{$coupon_url = path('kupshop_orderingbundle_pdfcoupon', ['id_order' => $body.order.id, 'id_coupon' => $coupon.id, 'cf' => $cf], 0)}
|
|
<a href="{$coupon_url}" target="_blank">{$coupon.code}</a>{if !$coupon@last},{/if}
|
|
{/foreach}
|
|
{/if}
|
|
</div>
|
|
<div class="col-xs-2 product-pieces">
|
|
{if $product.id_product}
|
|
{$product.pieces} {t}ks{/t}
|
|
{/if}
|
|
</div>
|
|
<div class="col-xs-2 product-price-total">
|
|
{$product.total_price.value_with_vat|format_price:"ceil=no;decimal=dynamic"}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{/foreach}
|
|
</div>
|
|
{/block}
|
|
|
|
{block "discounts"}
|
|
{get_order_items_discounts order=$body.order assign='itemsDiscounts'}
|
|
{if $itemsDiscounts}
|
|
<div class="row">
|
|
<div class="col-xs-6">
|
|
<h3>* {t}Aplikované slevy{/t}</h3>
|
|
<table class="price-box table" style="float: left;">
|
|
{$totalDiscounts = DecimalConstants::zero()}
|
|
{foreach $itemsDiscounts as $discount}
|
|
<tr>
|
|
<td>{$discount.name}</td>
|
|
<td><span class="pull-right">{$discount.totalPrice|format_price:"ceil=no;decimal=dynamic"}</span></td>
|
|
</tr>
|
|
{$totalDiscounts = $totalDiscounts->add($discount.totalPrice)}
|
|
{/foreach}
|
|
<tr>
|
|
<td class="strong"><b>{t}Celkem jste ušetřili{/t}</b></td>
|
|
<td class="strong"><b><span class="pull-right">{$totalDiscounts|format_price:"ceil=no;decimal=dynamic"}</span></b></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{/block}
|
|
|
|
{block "wtf"}
|
|
{block "price"}
|
|
<div class="row cart-row">
|
|
<div class="col-xs-12 col-md-5 pull-right">
|
|
<div class="price-box">
|
|
<div class="row">
|
|
<div class="col-xs-6">
|
|
<p>{t}Cena bez DPH{/t}:</p>
|
|
</div>
|
|
<div class="col-xs-6 text-right">
|
|
<p>{$body.order.total_price_array.value_without_vat|format_price:"ceil=no"}</p>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<div class="col-xs-6">
|
|
<p class="total-price">{t}Cena celkem{/t}:</p>
|
|
</div>
|
|
<div class="col-xs-6 text-right">
|
|
<h3>{$body.order.total_price_array|format_price}</h3>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{/block}
|
|
{/block}
|
|
</div>
|
|
{/change_currency}
|
|
{/block}
|
|
|
|
<script>
|
|
{block onready append}
|
|
wpj.domUtils.initOpeners();
|
|
{/block}
|
|
</script>
|