183 lines
8.3 KiB
Smarty
183 lines
8.3 KiB
Smarty
{* @compiler:inline-only *}
|
|
{* omezeni delky inputu kvuli Swisspost *}
|
|
{if $cfg.Order.Countries['CH']}{$isSwiss = true}{/if}
|
|
|
|
<form name="login" method="post" action="" data-form="user">
|
|
{get_contexts country=1 assign='contexts'}
|
|
{include "block.messages.tpl"}
|
|
|
|
<p class="title-default">{t}Účet{/t}</p>
|
|
|
|
<div class="row">
|
|
<div class="col-xxs-12 col-sm-6">
|
|
<div class="form-group required">
|
|
<label for="email">{t}E-mail{/t}</label>
|
|
<input type="email" name="email" id="email" class="form-control smartform-instance-invoice smartform-email" value="{$body.input.email.value}"
|
|
data-bv-notempty="true" data-bv-emailaddress-message="{t}Zadejte platnou e-mailovou adresu{/t}">
|
|
</div>
|
|
</div>
|
|
|
|
{block "password"}
|
|
<div class="col-xxs-12 col-sm-6">
|
|
{if $body.newUser}
|
|
<div class="form-group form-group-legend required">
|
|
<label for="password">{t}Heslo{/t}</label>
|
|
<input type="password" name="password" id="password" class="form-control" value=""
|
|
data-bv-notempty="true" data-bv-stringlength="true" data-bv-stringlength-min="6">
|
|
|
|
<a href="#" data-toggle-password>{t}Zobrazit{/t}</a>
|
|
</div>
|
|
{else}
|
|
<div class="form-group form-group-legend">
|
|
<label for="password">{t}Nové heslo{/t}</label>
|
|
<input type="password" name="password" id="password" class="form-control" value=""
|
|
data-bv-stringlength="true" data-bv-stringlength-min="6">
|
|
<a href="#" data-toggle-password>{t}Zobrazit{/t}</a>
|
|
</div>
|
|
{/if}
|
|
</div>
|
|
{/block}
|
|
</div>
|
|
|
|
<div class="row">
|
|
<div class="col-xxs-12">
|
|
<p class="title-default">{t}Kontaktní údaje{/t}</p>
|
|
</div>
|
|
<div class="col-xxs-12 col-sm-6">
|
|
<div class="form-group">
|
|
<label for="name">{t}Jméno{/t}</label>
|
|
<input type="text" name="name" id="name" class="form-control" value="{$body.input.name.value}"
|
|
data-bv-stringlength="true" data-bv-stringlength-min="2"
|
|
{if $isSwiss}data-bv-stringlength-max="14"{/if}>
|
|
</div>
|
|
</div>
|
|
<div class="col-xxs-12 col-sm-6">
|
|
<div class="form-group">
|
|
<label for="surname">{t}Příjmení{/t}</label>
|
|
<input type="text" name="surname" id="surname" class="form-control" value="{$body.input.surname.value}"
|
|
data-bv-stringlength="true" data-bv-stringlength-min="2"
|
|
{if $isSwiss}data-bv-stringlength-max="20"{/if}>
|
|
</div>
|
|
</div>
|
|
{block "user-phone"}
|
|
<div class="col-xxs-12 col-sm-6">
|
|
<div class="form-group">
|
|
<label for="phone">{t}Telefon{/t}</label>
|
|
<input type="tel" name="phone" id="phone" class="form-control smartform-instance-invoice smartform-phone-number" value="{$body.input.phone.value}"
|
|
data-bv-phone="true" data-bv-phone-country="country"
|
|
data-bv-phone-message="{t}Zadejte platné telefoní číslo{/t}">
|
|
</div>
|
|
</div>
|
|
{/block}
|
|
|
|
<div class="col-xxs-12">
|
|
<p class="title-default">{t}Adresa{/t}</p>
|
|
</div>
|
|
{block "user-street"}
|
|
<div class="col-xxs-12 col-sm-6">
|
|
<div class="form-group">
|
|
<label for="street">{t}Ulice a č.p.{/t}</label>
|
|
<input type="text" name="street" id="street" class="form-control smartform-instance-invoice smartform-address-street-and-number" value="{$body.input.street.value}"
|
|
{if $isSwiss}data-bv-stringlength="true" data-bv-stringlength-max="35"{/if}>
|
|
</div>
|
|
</div>
|
|
{/block}
|
|
<div class="col-xxs-12 col-sm-6">
|
|
<div class="zip-group">
|
|
<div class="form-group">
|
|
<label for="city">{t}Město{/t}</label>
|
|
<input type="text" name="city" id="city" class="form-control smartform-instance-invoice smartform-address-city" value="{$body.input.city.value}"
|
|
data-bv-stringlength="true" data-bv-stringlength-min="2"
|
|
{if $isSwiss}data-bv-stringlength="true" data-bv-stringlength-max="35"{/if}>
|
|
</div>
|
|
|
|
{block "user-zip"}
|
|
<div class="form-group">
|
|
<label for="zip">{t}PSČ{/t}</label>
|
|
<input type="text" name="zip" id="zip" class="form-control smartform-instance-invoice smartform-address-zip" value="{$body.input.zip.value}"
|
|
data-bv-zipcode="true" data-bv-zipcode-country="country"
|
|
data-bv-zipcode-message="{t}Zadejte platné PSČ{/t}">
|
|
</div>
|
|
{/block}
|
|
</div>
|
|
</div>
|
|
|
|
{* nechtějí mít zbytečné fieldy na registraci *}
|
|
{if !$body.newUser}
|
|
<div class="col-xxs-12 col-sm-6">
|
|
<div class="form-group">
|
|
<label for="firm">{t}Upřesnění adresy (firma, areál,…){/t}</label>
|
|
<input type="text" name="firm" id="firm" class="form-control" value="{$body.input.firm.value}"
|
|
{if $isSwiss}data-bv-stringlength="true" data-bv-stringlength-max="35"{/if}>
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
|
|
{block "user-country"}
|
|
<div class="col-xxs-12 col-sm-6">
|
|
<div class="form-group">
|
|
<label for="country">{t}Stát{/t}</label>
|
|
<select name="country" class="form-control custom-select" id="country"
|
|
{if $cfg.Order.Countries|count == 1}readonly{/if}>
|
|
|
|
{$activeCountry = $body.input.country.value|default:$ctrl.active_country}
|
|
|
|
{foreach $contexts.country->getAll() as $country}
|
|
<option value="{$country->getId()}" {if $activeCountry == $country->getId()}selected{/if}>
|
|
{$country->getName()}
|
|
</option>
|
|
{/foreach}
|
|
</select>
|
|
</div>
|
|
</div>
|
|
{/block}
|
|
</div>
|
|
|
|
<div class="form-group">
|
|
<label for="news" class="custom-checkbox custom-control">
|
|
<input type="checkbox" class="custom-control-input" name="news" id="news" value="Y" {$body.input.news|checked:'Y'}>
|
|
<span class="custom-control-indicator"></span>
|
|
{t escape=false}Dostávat novinky{/t} {* escape false kvuli pcch *}
|
|
{* @formatter:off *}
|
|
{if $dbcfg.gdpr.enable == 'Y'}
|
|
{block 'user-form-news-consent'}
|
|
{strip}
|
|
<small>
|
|
{if ($body.input.news == 'Y') and $body.input.date_subscribe.value}
|
|
({t date=$body.input.date_subscribe.value|date_format:"%d. %m. %Y"}Souhlas udělen dne {date}{/t})
|
|
{else}
|
|
(<a href="{url s=page label=consent}" target="_blank">{t}Souhlasím se zpracováním osobních údajů{/t}</a>)
|
|
{/if}
|
|
</small>
|
|
{/strip}
|
|
{/block}
|
|
{/if}
|
|
{* @formatter:on *}
|
|
</label>
|
|
</div>
|
|
|
|
<div class="registration-submit">
|
|
{if $body.newUser}
|
|
{if $dbcfg.gdpr.enable == 'Y'}
|
|
{* @formatter:off *}
|
|
{block 'user-form-consent-text'}
|
|
<p class="registration-consent">{t consent={url s=page label=consent} privacyPolicy={url s=page label=privacy_policy}
|
|
escape=false}Odesláním registrace souhlasím se <a href="{consent}" target="_blank">zpracováním osobních údajů za účelem registrace</a>
|
|
a beru na vědomí <a href="{privacyPolicy}" target="_blank">Zásady zpracování osobních údajů</a>.{/t}
|
|
</p>
|
|
{/block}
|
|
{* @formatter:on *}
|
|
{/if}
|
|
|
|
{if findModule('recaptcha','registration') and findModule('recaptcha','site_invisible')}
|
|
{include "block.recaptcha.invisible.tpl"}
|
|
{captchaBtn text="{t}Odeslat registraci{/t}"}
|
|
{else}
|
|
<input class="btn btn-primary" type="submit" name="Submit" value="{t}Odeslat registraci{/t}">
|
|
{/if}
|
|
{else}
|
|
<input class="btn btn-primary" type="submit" name="Submit" value="{t}Uložit{/t}">
|
|
{/if}
|
|
</div>
|
|
</form>
|