{foreach from=$list item=i}
    <tr class="{if $i.archive>0}archive{/if}{if $i.warning_nb_paniers} warning{/if}{if $i.nb_paniers_restants<=0} danger{/if}">
        <td class="center visible-lg id">{$i.ref}</td>
        <td class="name"><a href="#" class="btnViewContrat" ref={$i.ref}>{$i.client_prenom} {$i.client_nom}</a></td>
        <td class="visible-lg groupe">{$i.groupe_nom}</td>
        <td class="visible-lg contrat_type">{$i.type_nom}</td>
        <td class="visible-md visible-lg center date">{$i.date_print}</td>
        <td class="visible-md visible-lg center freq">{$i.frequence_print}</td>
        <td class="visible-md visible-lg center panier_type">{$i.panier_type_nom}</td>
        <td class="visible-md visible-lg center items_long">{$i.nb_paniers_livres} / {$i.nb_paniers}</td>
        <td class="visible-lg center items_long">{$i.nb_paniers_restants}{if $i.force_eligible>0} <i class="glyphicon glyphicon-star"></i>{/if}</td>
        <td class="visible-md visible-lg center lieu">{$i.lieu_depot_nom}</td>
        <td class="td_btn_action"><button class="btn btn-xs btn-link glyphicon glyphicon-edit btnEditContrat" ref="{$i.ref}"></button></td>
        {if $i.nb_paniers_livres_absolute>0}
        {if $i.archive>0}
        <td class="td_btn_action td_btn_unarchive"><button class="btn btn-xs btn-link glyphicon glyphicon-folder-open btnUnarchiveContrat" ref="{$i.ref}" nom="{$i.client_prenom} {$i.client_nom}"></button></td>
        {else}
        <td class="td_btn_action td_btn_archive"><button class="btn btn-xs btn-link glyphicon glyphicon-folder-close btnArchiveContrat" ref="{$i.ref}" nom="{$i.client_prenom} {$i.client_nom}"></button></td>
        {/if}
        {else}
        <td class="td_btn_action td_btn_delete"><button class="btn btn-xs btn-link glyphicon glyphicon-trash btnDeleteContrat" ref="{$i.ref}" nom="{$i.client_prenom} {$i.client_nom}"></button></td>
        {/if}
    </tr>
{foreachelse}
    <tr>
        <td colspan="12">aucun contrat</td>
    </tr>
{/foreach}