186 lines
9.1 KiB
Smarty
186 lines
9.1 KiB
Smarty
{extends "../frame.tpl"}
|
|
|
|
{block content}
|
|
<div class="container-fluid">
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<div class="row">
|
|
<div class="col-md-4">
|
|
<div class="panel panel-default first">
|
|
<div class="panel-heading">
|
|
<h3 class="panel-title">Načteno</h3>
|
|
</div>
|
|
<ul class="list-group">
|
|
<li class="list-group-item">
|
|
<span class="badge badge-default">{$import->stats['products']}</span>
|
|
produktů
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span class="badge badge-default">{$import->stats['variations']}</span>
|
|
variant
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="col-md-4">
|
|
<div class="panel panel-default first">
|
|
<div class="panel-heading">
|
|
<h3 class="panel-title">Vytvořeno</h3>
|
|
</div>
|
|
<ul class="list-group">
|
|
<li class="list-group-item">
|
|
<span class="badge badge-default">{$import->stats['products_created']}</span>
|
|
produktů
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span class="badge badge-default">{$import->stats['variations_created']}</span>
|
|
variant
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="col-md-4">
|
|
<div class="panel panel-default first">
|
|
<div class="panel-heading">
|
|
<h3 class="panel-title">Aktualizováno</h3>
|
|
</div>
|
|
<ul class="list-group">
|
|
<li class="list-group-item">
|
|
<span class="badge badge-default">{$import->stats['products_updated']}</span>
|
|
produktů
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span class="badge badge-default">{$import->stats['variations_updated']}</span>
|
|
variant
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
</div>
|
|
|
|
{if $import->stats['deleted']}
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<h1 class="h4 main-panel-title">{count($import->stats['deleted'])}</h1>
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
|
|
{$size = 0}
|
|
{foreach $columns as $name}
|
|
{$size = $size+$fields[$name].size|default:1}
|
|
{/foreach}
|
|
{if in_array('import_error', $columns)}
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<h1 class="h4 main-panel-title">Následující produkty nebyly naimportovány z důvodu chyby </h1>
|
|
</div>
|
|
</div>
|
|
|
|
<table class="table table-striped" style="text-align:center;min-width: 1024px;">
|
|
<thead>
|
|
<tr>
|
|
{foreach $columns as $name}
|
|
<th style="min-width: {$fields[$name].size|default:1*50}px;">{$fields[$name].name nofilter}</th>
|
|
{/foreach}
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{foreach $products as $product}
|
|
{if !empty($product.import_error)}
|
|
<tr class="{if $product['error']}errorLine{/if}">
|
|
{foreach $columns as $name}
|
|
<td>
|
|
{$import->debugPrintValue($name, $product)}
|
|
</td>
|
|
{/foreach}
|
|
|
|
{if $product.variations}
|
|
<td>
|
|
<table class="table table-striped">
|
|
<tr>
|
|
{foreach $columnsVariations as $name}
|
|
<th>{$fields[$name].name nofilter}</th>
|
|
{/foreach}
|
|
</tr>
|
|
{foreach $product['variations'] as $variation}
|
|
<tr>
|
|
{foreach $columnsVariations as $name}
|
|
<td>
|
|
{$import->debugPrintValue($name, $variation)}
|
|
</td>
|
|
{/foreach}
|
|
</tr>
|
|
{/foreach}
|
|
</table>
|
|
</td>
|
|
{/if}
|
|
</tr>
|
|
{/if}
|
|
{/foreach}
|
|
</tbody>
|
|
</table>
|
|
{/if}
|
|
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<h1 class="h4 main-panel-title">Změněné produkty {if !$all}(prvních 1000 produktů){/if}</h1>
|
|
</div>
|
|
</div>
|
|
|
|
<table class="table table-striped" style="min-width: 1024px;">
|
|
<thead>
|
|
<tr>
|
|
{foreach $columns as $name}
|
|
<th style="min-width: {$fields[$name].size|default:1*50}px;">{$fields[$name].name nofilter}</th>
|
|
{/foreach}
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{if $import->stats['products_created'] > 0 || $import->stats['products_updated'] > 0}
|
|
{foreach $updatedProducts as $product}
|
|
{if empty($product.error)}
|
|
<tr>
|
|
{foreach $columns as $name}
|
|
<td>
|
|
{$import->debugPrintValue($name, $product)}
|
|
</td>
|
|
{/foreach}
|
|
|
|
{if $product.variations}
|
|
<td>
|
|
<table class="table table-striped">
|
|
<tr>
|
|
{foreach $columnsVariations as $name}
|
|
<th>{$fields[$name].name nofilter}</th>
|
|
{/foreach}
|
|
</tr>
|
|
{foreach $product['variations'] as $variation}
|
|
<tr>
|
|
{foreach $columnsVariations as $name}
|
|
<td>
|
|
{$import->debugPrintValue($name, $variation)}
|
|
</td>
|
|
{/foreach}
|
|
</tr>
|
|
{/foreach}
|
|
</table>
|
|
</td>
|
|
{/if}
|
|
</tr>
|
|
{if $all != 1 && $product@iteration > 50}
|
|
{break}
|
|
{/if}
|
|
{/if}
|
|
{/foreach}
|
|
{/if}
|
|
</tbody>
|
|
</table>
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{/block}
|