Files
kupshop/web/templates/x/ordering/ordering.delivery.country.tpl
2025-08-02 16:30:27 +02:00

20 lines
987 B
Smarty

<div class="delivery-country">
<label for="delivery-country" class="title-default">{t}Vyberte zemi doručení{/t}</label>
<div class="delivery-country-select">
{get_contexts country=1 assign='contexts'}
{$activeCountry = $contexts.country->getActive()}
<span class="country-flag" style="background-image: url('/common/static/images/flags/{$activeCountry.id|lower}.svg')"></span>
<select class="form-control" name="delivery-country" id="{$select_id|default:"delivery-country"}">
{if findModule(Modules::ORDERS, Modules::SUB_COUNTRY_SELECTION)}
{$countries = $contexts.country->getSupported()}
{else}
{$countries = $contexts.country->getAll()}
{/if}
{foreach $countries as $country}
<option value="{$country->getId()}"
{if $country->getId() == $activeCountry->getId()}selected{/if}>{$country->getName()}</option>
{/foreach}
</select>
</div>
</div>