{extends file="triggers/trigger.tpl"}

{block "trigger"}
{get_contexts currency=1 assign="contexts"}
<div class="form-group">
   <div class="col-md-3 control-label">
      <label>{'currency'|translate:'users'}</label>
   </div>
   <div class="col-md-5">
      {if $data.currency}
         {$data.currency = array_combine($data.currency, $data.currency)}
      {/if}
      <div class="input-group invert">
         <select class="selecter" name="{$name}[data][currency][]" multiple='multiple'>
            {foreach $contexts.currency->getSupported() as $cur}
               <option value="{$cur->getId()}" {if array_key_exists($cur->getId(), $data.currency)}selected="selected"{/if}>{$cur->getName()}</option>
            {/foreach}
         </select>
         {inversion_trigger field="currency" checked="{if $data.currency_invert}checked{/if}"}
      </div>
   </div>
</div>
{/block}
