mercredi 14 juillet 2021

limit foreach prints inside div layer

How can I limit the impressions of the foreach ?.

I need only 7 rows horizontal to print. is there any way to do it with css or pagination?

Image the problem: https://i.imgur.com/LwhA42z.png

right now print infinity, the design is deformed

 <div class="col-xl-6 col-lg-12 col-md-12 col-sm-12 col-12 layout-spacing">
            <div class="widget widget-table-two">

                <div class="widget-heading">
                    <h5 class="">Turnos Recientes</h5>
                </div>

                <div class="widget-content">
                    <div class="table-responsive">
                        <table class="table">
                            <thead>
                          
                                <tr>
                                    <th><div class="th-content">Cliente</div></th>
                                    <th><div class="th-content">Servicio</div></th>
                                    <th><div class="th-content mr-3">Horario</div></th>
                                    <th><div class="th-content ml-3">Asistencia</div></th>
                                    <th><div class="th-content mr-3">Estado</div></th>
                                </tr>
                        
                            </thead>
                            <tbody>
                            @foreach ($servicios as $servicio)
                                <tr>
                                <td><div class="td-content customer-name"></div></td>
                                    <td><div class="td-content product-brand"></div></td>
                                    <td><div class="td-content ml-2"></div></td>
                                    <td><div class="td-content"> 
                                    @if($servicio->asistencia == 'on')
                                    Sí
                                    @elseif($servicio->asistencia == null)
                                    No
                                    @endif
                                
                </div></td>
                                    <td><div class="td-content">
                                    @if($servicio->c_confirma == 'on')
                                    <span class="badge outline-badge-primary">Confirmado</span>
                                    @elseif($servicio->c_confirma == null)
                                    <span class="badge outline-badge-danger">Sin Confirmar</span>
                                    @endif
                                    </span></div></td>
                                </tr>
                                @endforeach
                             
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
        </div>


via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire