<div class="table-responsive" style="max-height:200px;overflow-y:scroll">
    <table id="dataTable" class="table table-head-fixed table-bordered ">
        <thead class="bg-gray-50">
            <tr>
                <th>ID</th>
                <th>User name</th>
                <th>Expire Date</th>
                <th>Bill Cycle</th>
                <th>Package</th>
                <th>Sub Package</th>
                <th>Contact No</th>
                <th>Name</th>
                <th>Reseller</th>
                <th></th>
            </tr>
        </thead>
        <tbody class="bg-white divide-y divide-gray-200">
            @foreach ($list as $r)
                <tr>
                    <td>
                        {{ $r->id }}
                        <input type="hidden" id="client_id" value=" {{ $r->id }}">
                    </td>
                    <td>
                        {{ $r->userid }}
                    </td>

                    <td class="whitespace-nowrap">
                        {{ date('d-M-Y', strtotime($r->expire_date)) }}
                    </td>


                    <td>
                        {{ $r->billing_cycle }}
                    </td>

                    <td>
                        {{ $r->packages->package_name }}
                    </td>

                    <td>

                    </td>

                    <td>
                        {{ $r->clientsinfo->contact_no ?? '' }}
                    </td>
                    <td>
                        {{ $r->clientsinfo->clients_name ?? '' }}
                    </td>
                    <td>
                        {{ $r->pop->popname ?? '' }}
                    </td>
                    <td class="px-6 text-left text-sm font-medium">

                        <a class="btn btn-primary btn-xs" href="{{ route('tokenCreate', $r->id) }}">
                            Add Token
                        </a>
                        <button type="submit" data-id="{{ $r->id }}"
                            class="clickDetails btn btn-info btn-xs">Details</button>

                        {{-- @if ($r->clients_status == 'disable')
                        @can('id-enable')
                            <a href="{{ route('idEnable', $r->id) }}"
                                onclick="return confirm('Are you sure you want to Enable the ID?');"
                                class="inline-flex text-xs justify-center py-1 text-white px-2 mt-2 ml-5 border border-transparent shadow-sm font-medium rounded-sm block bg-green-600 hover:bg-green-900">Enable</a>

                        @endcan
                    @endif

                    @if ($r->clients_status == 'active')
                        @can('id-disable')
                            <a href="{{ route('idDisable', $r->id) }}"
                                onclick="return confirm('Are you sure you want to Disable the ID?');"
                                class="confirmDisable inline-flex text-xs justify-center py-1 text-white px-2 mt-2 ml-5 border border-transparent shadow-sm font-small rounded-sm block bg-yellow-600 hover:bg-red-900">Disable</a>

                        @endcan
                    @endif --}}
                    </td>
                </tr>
            @endforeach
            <!-- More items... -->
        </tbody>
    </table>
</div>
