Review html for the forms
- Remove icon error from html (Added with css) - Add maxlenght - Remove class has-success - Translate placeholder - Confirm dialog to delete an address
This commit is contained in:
@@ -24,7 +24,6 @@
|
||||
<h1 id="main-label" class="page-header">{intl l="Update Profile"}</h1>
|
||||
|
||||
{form name="thelia.front.customer.profile.update"}
|
||||
{assign var="isPost" value="{$smarty.post|count}"}
|
||||
<form id="form-register" class="form-horizontal" action="{url path="/account/update"}" method="post" role="form">
|
||||
{form_field form=$form field='success_url'}
|
||||
<input type="hidden" name="{$name}" value="{url path="/account"}" />
|
||||
@@ -41,7 +40,7 @@
|
||||
|
||||
<div class="panel-body">
|
||||
{form_field form=$form field="title"}
|
||||
<div class="form-group group-title {if $error}has-error{elseif $isPost && $value != "" && !$error}has-success{/if}">
|
||||
<div class="form-group group-title{if $error} has-error{/if}">
|
||||
<label class="control-label" for="{$label_attr.for}">{$label}{if $required} <span class="required">*</span>{/if}</label>
|
||||
<div class="control-input">
|
||||
<select name="{$name}" id="{$label_attr.for}" class="form-control"{if $required} aria-required="true" required{/if}{if !$value || $error} autofocus{/if}>
|
||||
@@ -50,56 +49,48 @@
|
||||
<option value="{$ID}" {if $value == $ID}selected{/if} >{$LONG}</option>
|
||||
{/loop}
|
||||
</select>
|
||||
{if $error }
|
||||
<span class="help-block"><i class="icon-remove"></i> {$message}</span>
|
||||
{if $error}
|
||||
<span class="help-block">{$message}</span>
|
||||
{assign var="error_focus" value="true"}
|
||||
{elseif !$value}
|
||||
{assign var="error_focus" value="true"}
|
||||
{elseif $isPost && $value != "" && !$error}
|
||||
<span class="help-block"><i class="icon-ok"></i></span>
|
||||
{/if}
|
||||
</div>
|
||||
</div><!--/.form-group-->
|
||||
{/form_field}
|
||||
{form_field form=$form field="firstname"}
|
||||
<div class="form-group group-firstname {if $error}has-error{elseif $isPost && $value != "" && !$error}has-success{/if}">
|
||||
<div class="form-group group-firstname {if $error}has-error{/if}">
|
||||
<label class="control-label" for="{$label_attr.for}">{$label}{if $required} <span class="required">*</span>{/if}</label>
|
||||
<div class="control-input">
|
||||
<input type="text" name="{$name}" id="{$label_attr.for}" class="form-control" placeholder="John" value="{$value}" {if $required} aria-required="true" required{/if}{if !isset($error_focus) && $error} autofocus{/if}>
|
||||
<input type="text" name="{$name}" id="{$label_attr.for}" class="form-control" maxlength="255" placeholder="{intl l="Placeholder firstname"}" value="{$value}"{if $required} aria-required="true" required{/if}{if !isset($error_focus) && $error} autofocus{/if}>
|
||||
{if $error }
|
||||
<span class="help-block"><i class="icon-remove"></i> {$message}</span>
|
||||
<span class="help-block">{$message}</span>
|
||||
{assign var="error_focus" value="true"}
|
||||
{elseif $isPost && $value != "" && !$error}
|
||||
<span class="help-block"><i class="icon-ok"></i></span>
|
||||
{/if}
|
||||
</div>
|
||||
</div><!--/.form-group-->
|
||||
{/form_field}
|
||||
{form_field form=$form field="lastname"}
|
||||
<div class="form-group group-lastname {if $error}has-error{elseif $isPost && $value != "" && !$error}has-success{/if}">
|
||||
<div class="form-group group-lastname {if $error}has-error{/if}">
|
||||
<label class="control-label" for="{$label_attr.for}">{$label}{if $required} <span class="required">*</span>{/if}</label>
|
||||
<div class="control-input">
|
||||
<input type="text" name="{$name}" id="{$label_attr.for}" class="form-control" placeholder="Doe" value="{$value}" {if $required} aria-required="true" required{/if}{if !isset($error_focus) && $error} autofocus{/if}>
|
||||
<input type="text" name="{$name}" id="{$label_attr.for}" class="form-control" maxlength="255" placeholder="{intl l="Placeholder lastname"}" value="{$value}" {if $required} aria-required="true" required{/if}{if !isset($error_focus) && $error} autofocus{/if}>
|
||||
{if $error }
|
||||
<span class="help-block"><i class="icon-remove"></i> {$message}</span>
|
||||
<span class="help-block">{$message}</span>
|
||||
{assign var="error_focus" value="true"}
|
||||
{elseif $isPost && $value != "" && !$error}
|
||||
<span class="help-block"><i class="icon-ok"></i></span>
|
||||
{/if}
|
||||
</div>
|
||||
</div><!--/.form-group-->
|
||||
{/form_field}
|
||||
{form_field form=$form field="email"}
|
||||
<div class="form-group group-email {if $error}has-error{elseif $isPost && $value != "" && !$error}has-success{/if}">
|
||||
<div class="form-group group-email {if $error}has-error{/if}">
|
||||
<label class="control-label" for="{$label_attr.for}">{$label}{if $required} <span class="required">*</span>{/if}</label>
|
||||
|
||||
<div class="control-input">
|
||||
<input type="email" name="{$name}" id="{$label_attr.for}" class="form-control" placeholder="johndoe@domain.com" value="{$smarty.get.email|default:$value}"{if $required} aria-required="true" required{/if}{if !isset($error_focus) && $error} autofocus{/if}>
|
||||
<input type="email" name="{$name}" id="{$label_attr.for}" class="form-control" maxlength="255" placeholder="{intl l="Placeholder email"}" value="{$smarty.get.email|default:$value}"{if $required} aria-required="true" required{/if}{if !isset($error_focus) && $error} autofocus{/if}>
|
||||
{if $error }
|
||||
<span class="help-block"><i class="icon-remove"></i> {$message}</span>
|
||||
<span class="help-block">{$message}</span>
|
||||
{assign var="error_focus" value="true"}
|
||||
{elseif $isPost && $value != "" && !$error}
|
||||
<span class="help-block"><i class="icon-ok"></i></span>
|
||||
{/if}
|
||||
</div>
|
||||
</div><!--/.form-group-->
|
||||
@@ -115,7 +106,7 @@
|
||||
<input type="checkbox" name="{$name}" id="{$label_attr.for}" value="{$value}"{if $checked} checked{/if} {if $required} aria-required="true" required{/if}>{$label}
|
||||
</label>
|
||||
{if $error }
|
||||
<span class="help-block"><i class="icon-remove"></i> {$message}</span>
|
||||
<span class="help-block">{$message}</span>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user