{extends file="[shared]/menu.tpl"}

{block name="menu-items"}
   <ul class="nav nav-pills nav-stacked">
      <li class="nav-header"><i class="glyphicon glyphicon-tags"></i><span>{translate_type type=$type}</li>
      <li><a href="javascript:nf('', 'launch.php?s=list.php&amp;type={$type}');"><i class="glyphicon glyphicon-list"></i>
            <span>{'toolbar_list'|translate}</span></a></li>
      <li>
         <ul class="nav-sub nav-pills">
            <form class="form-inline" target="mainFrame" method="get">
               <input type="hidden" name="type" value="preordersUsers"/>
               <input type="hidden" name="s" value="list.php"/>
               <div style="flex-direction: column;" class="d-flex form-group">
                  <div class="form-group">
                     <select class="selecter"
                             name="id_user[]"
                             multiple
                             data-autocomplete="users"
                             data-placeholder="Vyberte uživatele"
                     ></select>
                  </div>

                  <div class="form-group">
                     <select class="selecter"
                             name="id_preorder[]"
                             multiple
                             data-autocomplete="preorders"
                             data-autocomplete-params="entity_type=preorders"
                             data-placeholder="Vyberte předobjednávky"
                     ></select>
                  </div>

                  <div class="form-group">
                     <select class="selecter"
                             name="id_preorder_date[]"
                             multiple
                             data-autocomplete="preorders"
                             data-autocomplete-params="entity_type=preorders_dates"
                             data-placeholder="Vyberte termíny"
                     ></select>
                  </div>

                  <div class="form-group">
                     <div class="checkbox">
                        <input type="checkbox" class="input" name="onlyClosed" id="onlyClosed">
                        <label for="onlyClosed">Pouze z uzavřených termínů</label>
                     </div>
                  </div>

                  <div class="form-group">
                     <div class="checkbox">
                        <input type="checkbox" class="input" name="onlyUnsent" id="onlyUnsent">
                        <label for="onlyUnsent">Pouze s neodeslanými produkty</label>
                     </div>
                  </div>
                  <div style="flex-direction: column; margin-top: 1em;" class="d-flex form-group">
                     <div class="form-group">
                        <div class="checkbox">
                           <input type="checkbox" class="input" name="allUsers" id="allUsers">
                           <label for="allUsers">Zobrazit všechny uživatele</label>
                        </div>
                     </div>

                     <div class="form-group">
                        <select class="selecter"
                                name="id_users_group[]"
                                multiple
                                data-autocomplete="users_groups"
                                data-placeholder="Vyberte skupiny uživatelů"
                        ></select>
                     </div>
                  </div>

                  <div class="d-flex justify-content-end">
                     <button type="submit" class="btn btn-primary" title="Vyhledat uživatele">
                        <i class="glyphicon glyphicon-search"></i>
                        <span>Vyhledat</span>
                     </button>
                  </div>
               </div>
            </form>
         </ul>
      </li>
   </ul>
{/block}
