{extends file="admin-layout.tpl"} {block name="no-return-functions"} {$admin_current_location = 'configuration'} {/block} {block name="page-title"}{intl l='Edit a country'}{/block} {block name="check-resource"}admin.configuration.country{/block} {block name="check-access"}update{/block} {block name="main-content"}
{loop name="country_edit" type="country" id="$country_id" backend_context="1" lang="$edit_language_id" visible="*"}
{hook name="country-edit.top" country_id=$country_id}
{intl l='Edit country "%name"' name="{$TITLE}"}
{form name="thelia.admin.country.modification"} {include file = "includes/inner-form-toolbar.html" hide_submit_buttons = false page_url = {url path="/admin/configuration/country/update/%id" id=$ID} close_url = {url path="/admin/configuration/countries"} } {* Be sure to get the country ID, even if the form could not be validated *} {form_hidden_fields exclude="locale"} {render_form_field field='success_url' value={url path="/admin/configuration/countries"}} {render_form_field field='locale' value={$edit_language_locale}} {if $form_error}
{$form_error_message}
{/if}
{render_form_field field="visible"} {include file="includes/standard-description-form-fields.html"}
{render_form_field field="isocode"} {render_form_field field="isoalpha2"} {render_form_field field="isoalpha3"} {render_form_field field="has_states"} {render_form_field field="need_zip_code"} {render_form_field field="zip_code_format"}

### {intl l="Shipping zones for this country"}

{ifloop rel="country-areas"}

{loop name="country-areas" type="area" country=$country_id backend_context="1"}
- {$NAME}
{/loop}

{/ifloop} {elseloop rel="country-areas"}
{intl l="This country is not included in any shipping zone"}
{/elseloop}
{/form} {ifloop rel="states"} {loop type="auth" name="can_change" role="ADMIN" resource="admin.configuration.state" access="UPDATE"} {$canEditState=true} {/loop}

### {intl l="States/provinces assigned to this country"}

{loop name="states" type="state" country=$country_id visible="*" backend_context="1"}
{$ID}. {$TITLE} {if $canEditState} | {intl l="Edit"} {/if}
{/loop}

{/ifloop}
{hook name="country-edit.bottom" country_id=$country_id} {/loop} {elseloop rel="country_edit"}
{intl l="Sorry, country ID=%id was not found." id={$country_id}}
{/elseloop}
{/block} {block name="javascript-last-call"} {hook name="country.edit-js" location="country-edit-js" country_id=$country_id } {hook name="wysiwyg.js" location="wysiwyg-country-edit-js" } {/block}