<div class="col-lg-max">
    <div class="row">
        <div class="col-md-12" style="padding:14px">
            <div class="tab-pane" id="controles">
                <legend>Liste des controles</legend>
                <div class="form-group">
                    <div class="table-responsive">
                        @if(count($controles)>0)
                            <table id="_table_controles" style="background-color:white" class="table table-condensed table-striped table-bordered" >
                                <thead>
                                    <tr>
                                        <th nowrap width='1%'>N°</th>
                                        <th width='1px'>Contrôle</th>
                                        <th >Agent1</th>
                                        <th >Agent2</th> 
                                        <th width='1px'>Validation</th>
                                        <th width='40%'>Observations</th>
                                        <th width='1px'>&nbsp</th>
                                    </tr>
                                </thead>
                     
                                <tbody>
                                    @foreach ($controles as $controle)
                                    <tr>
                                        <td style="color:grey">{!! $controle->id !!}</td>
                                        <td align="center">{!! $controle->date_cont !!}</td>
                                        <td align="left">{!! $controle->agent1 !!}</td>
                                        <td align="left">{!! $controle->agent2 !!}</td>
                                        <td align="center">{!! $controle->date_valid !!}</td>
                                        <td align="left">{!! $controle->observations !!}</td>
                                        <td nowrap>
                                        @if($user->can("COT_VISU") || $user->HasRole("ADMINISTRATEUR"))
                                            <a href="{!! url('controles/show_box/'.$controle->id) !!}" 
                                                class="various fancybox.iframe btn btn-warning" 
                                                style="margin-right: 3px;">Détail</a>
                                        @endif 
                                        </td>
                                    </tr>
                                    @endforeach
                                </tbody>
                            </table>
                        @else
                            <h2><small><i>Aucun contrôle</i></small></h2>
                        @endif
                    </div>
                </div>
            </div> 
        </div>
    </div>
</div>