{extends file="layout.tpl"} {* Security *} {block name="no-return-functions" prepend} {check_auth role="CUSTOMER" login_tpl="login"} {/block} {* Body Class *} {block name="body-class"}page-address{/block} {* Breadcrumb *} {block name='no-return-functions' append} {$breadcrumbs = [ ['title' => {intl l="Account"}, 'url'=>{url path="/account"}], ['title' => {intl l="Address Update"}, 'url'=>{url path="/address/update/%address_id" address_id=$address_id}] ]} {/block} {block name="main-content"}

# {intl l="Address Update"}

{hook name="address-update.top"} {form name="thelia.front.address.update"} {loop name="customer.update" type="address" customer="current" id=$address_id} {form_field field='success_url'} {if $value} {$next_url=$value} {else} {$next_url=$smarty.get.next|default:{url path="/account"}} {/if} {/form_field} {form_field field='error_message'} {/form_field} {form_hidden_fields} {if $form_error}
{$form_error_message}
{/if} {hook name="address-update.form-top" address=$address_id}
{intl l="Address"}
{form_field field="label"}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {elseif !$value} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="title"} {assign var="customer_title_id" value={$value|default:$TITLE}}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="firstname"}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="lastname"}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="company"}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="address1"}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="address2"}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="zipcode"}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="city"}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="country"} {assign var="customer_country_id" value={$value|default:$COUNTRY}} {$countryFieldId=$label_attr.for}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="state"} {assign var="customer_state_id" value={$value|default:$STATE}}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="phone"}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field} {form_field field="cellphone"}
{$label}:{if $required} *{/if}
{if $error } {$message} {assign var="error_focus" value="true"} {/if}
{/form_field}
{form_field field="is_default"} {if not $DEFAULT}
{$label}
{/if} {/form_field} {hook name="address-update.form-bottom" address=$address_id}
{/loop} {/form} {hook name="address-update.bottom" address=$address_id}
{/block} {block name="stylesheet"} {hook name="address-update.stylesheet"} {/block} {block name="after-javascript-include"} {hook name="address-update.after-javascript-include" address=$address_id} {/block} {block name="javascript-initialization"} {hook name="address-update.javascript-initialization" address=$address_id} {/block}