* Add account * If user has checked "I'm a new customer", we must verify if it's a new email address.
76 lines
4.0 KiB
HTML
76 lines
4.0 KiB
HTML
{extends file="layout.tpl"}
|
|
|
|
{* Body Class *}
|
|
{block name="body-class"}page-login{/block}
|
|
|
|
{* Breadcrumb *}
|
|
{block name='no-return-functions' append}
|
|
{$breadcrumbs = [
|
|
['title' => {intl l="Login"}, 'url'=>{url path="/login"}]
|
|
]}
|
|
{/block}
|
|
|
|
|
|
{block name="main-content"}
|
|
<div class="main">
|
|
<article class="col-main" role="main" aria-labelledby="main-label">
|
|
<h1 id="main-label" class="page-header">{intl l="Login"}</h1>
|
|
{form name="thelia.customer.login"}
|
|
<form id="form-login" action="{url path="/login"}" method="post" role="form" {form_enctype form=$form}>
|
|
{if $form_error}<div class="alert alert-danger">{$form_error_message}</div>{/if}
|
|
{form_field form=$form field='success_url'}
|
|
<input type="hidden" name="{$name}" value="{navigate to="return_to"}"> {* the url the user is redirected to on login success *}
|
|
{/form_field}
|
|
|
|
{form_field form=$form field='error_message'}
|
|
<input type="hidden" name="{$name}" value="{intl l="missing or invalid data"}"> {* the url the user is redirected to on login success *}
|
|
{/form_field}
|
|
{form_hidden_fields form=$form}
|
|
<fieldset>
|
|
{form_field form=$form field="email"}
|
|
<div class="form-group group-email{if $error} has-error{/if}">
|
|
<label for="{$label_attr.for}">{$label}</label>
|
|
<div class="control-input">
|
|
<input type="email" name="{$name}" id="{$label_attr.for}" value="{$value}" class="form-control" {$attr} {if $required}aria-required="true" required{/if}{if $error} autofocus{/if}>
|
|
{if $error}
|
|
<span class="help-block"><span class="icon-remove"></span> {$message}</span>
|
|
{assign var="error_email" value="true"}
|
|
{/if}
|
|
</div>
|
|
</div>
|
|
{/form_field}
|
|
|
|
<fieldset>
|
|
{form_field form=$form field="account"}
|
|
<legend>{intl l="Do you have an account?"}</legend>
|
|
{foreach $choices as $choice}
|
|
<div class="radio radio-account{$choice->value}">
|
|
<label for="{$label_attr.for}{$choice->value}">
|
|
<input type="radio" name="{$name}" id="{$label_attr.for}{$choice->value}" data-toggle="password" value="{$choice->value}"{if $value === {$choice->value}} checked{/if}> {$choice->label}
|
|
</label>
|
|
</div>
|
|
{/foreach}
|
|
{/form_field}
|
|
{form_field form=$form field="password"}
|
|
<div class="form-group group-password{if $error} has-error{/if}">
|
|
<label for="{$label_attr.for}" class="sr-only">{$label}</label>
|
|
<div class="control-input">
|
|
<input type="password" name="{$name}" id="{$label_attr.for}" class="form-control" autocomplete="off"{if !isset($error_email) && $error } autofocus{/if}>
|
|
{if $error}
|
|
<span class="help-block"><span class="icon-remove"></span> {$message}</span>
|
|
{/if}
|
|
</div>
|
|
</div>
|
|
{/form_field}
|
|
</fieldset>
|
|
</fieldset>
|
|
|
|
<div class="group-btn">
|
|
<a href="{url path="/password"}" data-toggle="confirmation" class="forgot-password">{intl l="Forgot your Password?"}</a>
|
|
<button type="submit" class="btn btn-login">{intl l="Next"}</button>
|
|
</div>
|
|
</form>
|
|
{/form}
|
|
</article>
|
|
</div>
|
|
{/block} |