158 lines
6.9 KiB
Smarty
158 lines
6.9 KiB
Smarty
{extends "../frame.tpl"}
|
|
|
|
{block "content"}
|
|
<div class="container">
|
|
{if $errs || $info}
|
|
<div class="panel panel-default first">
|
|
<div class="panel-body">
|
|
{if $info['test'] == 1}
|
|
Test importu uživatelů.
|
|
<br/>
|
|
Počet přidaných:{$info['added']}.
|
|
{else}
|
|
Uživatelé importováni.
|
|
<br/>
|
|
Počet importovaných: {$info['added']}
|
|
{/if}
|
|
<br/>
|
|
|
|
{if count($errs) > 0}
|
|
Vyskytlo se {count($errs)} chyb:
|
|
<br/>
|
|
{else}
|
|
Nevyskytly se žádné chyby.
|
|
{/if}
|
|
<br/><br/>
|
|
|
|
{foreach $errs as $row => $err}
|
|
řádek: {$row} chyba: {$err}
|
|
<br/>
|
|
{/foreach}
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $added_users}
|
|
<div class="panel panel-default first">
|
|
<div class="panel-body">
|
|
|
|
<h4>Načtení uživatelé</h4>
|
|
|
|
<div style="overflow: auto; width: 100%;">
|
|
<table class="table">
|
|
<thead>
|
|
<tr>
|
|
<th style="width: 10%;">Jméno</th>
|
|
<th style="width: 10%;">Přijmení</th>
|
|
<th style="width: 10%;">Společnost</th>
|
|
<th style="width: 10%;">Email</th>
|
|
<th style="width: 10%;">Telefon</th>
|
|
<th style="width: 10%;">Ulice</th>
|
|
<th style="width: 10%;">Město</th>
|
|
<th style="width: 10%;">PSČ</th>
|
|
<th style="width: 10%;">Stát / region</th>
|
|
<th style="width: 10%;">Země</th>
|
|
<th style="width: 10%;">Skupiny</th>
|
|
<th style="width: 10%;">Newsletter</th>
|
|
<th style="width: 10%;">IČO</th>
|
|
<th style="width: 10%;">DIČ</th>
|
|
<th style="width: 10%;">Dodací jméno</th>
|
|
<th style="width: 10%;">Dodací příjmení</th>
|
|
<th style="width: 10%;">Dodací společnost</th>
|
|
<th style="width: 10%;">Dodací ulice</th>
|
|
<th style="width: 10%;">Dodací město</th>
|
|
<th style="width: 10%;">Dodací PSČ</th>
|
|
<th style="width: 10%;">Dodací stát / region</th>
|
|
<th style="width: 10%;">Dodací země</th>
|
|
<th style="width: 10%;">Cenová hladina</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{foreach $added_users as $user}
|
|
<tr>
|
|
<td>{$user.name}</td>
|
|
<td>{$user.surname}</td>
|
|
<td>{$user.firm}</td>
|
|
<td>{$user.email}</td>
|
|
<td>{$user.phone}</td>
|
|
<td>{$user.street}</td>
|
|
<td>{$user.city}</td>
|
|
<td>{$user.zip}</td>
|
|
<td>{$user.state}</td>
|
|
<td>{$user.country}</td>
|
|
<td>{foreach $user.groups as $group}{$group} {/foreach}</td>
|
|
<td>{$user.get_news}</td>
|
|
<td>{$user.ico}</td>
|
|
<td>{$user.dic}</td>
|
|
<td>{$user.delivery_name}</td>
|
|
<td>{$user.delivery_surname}</td>
|
|
<td>{$user.delivery_firm}</td>
|
|
<td>{$user.delivery_street}</td>
|
|
<td>{$user.delivery_city}</td>
|
|
<td>{$user.delivery_zip}</td>
|
|
<td>{$user.delivery_state}</td>
|
|
<td>{$user.delivery_country}</td>
|
|
<td>{$user.price_level}</td>
|
|
</tr>
|
|
{/foreach}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<div class="col-md-2">
|
|
<a href="" class="btn btn-primary btn-block">Zpět</a>
|
|
</div>
|
|
</div>
|
|
{else}
|
|
<form action="" method="post" enctype="multipart/form-data">
|
|
<div class="panel panel-default first">
|
|
<div class="panel-body">
|
|
<h4>Import uživatelů</h4>
|
|
|
|
<div class="panel panel-default">
|
|
<div class="panel-heading">
|
|
<h4 class="panel-title">Nápověda</h4>
|
|
</div>
|
|
<div class="panel-body">
|
|
<p>Rady a tipy pro import uživatelů můžete získat v naší
|
|
<a target="_blank" href="http://www.napoveda.wpj.cz/kupshop/uzivatele/import-uzivatelu/">nápovědě</a>.</p>
|
|
<strong><a href="/admin/static/files/users_import.xls">Vzorový excel soubor</a></strong>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="row bottom-space">
|
|
<div class="form-group">
|
|
<div class="col-md-3 control-label"><label>Importovaný Excel soubor</label></div>
|
|
<div class="col-md-5">
|
|
<input type="file" class="filestyle" name="file" data-iconName="glyphicon-folder-open"
|
|
data-buttonText="Vybrat soubor"/>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="row bottom-space">
|
|
<div class="form-group">
|
|
<div class="col-md-3 control-label"><label>Neodesílat potvzení o odběru novinek a potvrdit odběr</label></div>
|
|
<div class="col-md-5">
|
|
<div class="checkbox">
|
|
<input id="newsletter_confirm" class="check" type="checkbox" name="newsletter_confirm" value="1"/>
|
|
<label for="newsletter_confirm"></label>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="form-group">
|
|
<div class="col-md-2 col-md-offset-8">
|
|
<input type="submit" name="Try" class="btn btn-primary btn-block" value="Vyzkoušet">
|
|
</div>
|
|
<div class="col-md-2">
|
|
<input type="submit" name="Execute" class="btn btn-primary btn-block" value="Importovat">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
{/if}
|
|
</div>
|
|
{/block}
|