<div class="table-responsive">
    <table class="table p-0 m-0 table-sm table-striped table-bordered border-bottom text-nowrap">
        <thead class="bg-light">
            <tr>
                <th class="border-0">Date</th>
                <th class="border-0">Patient</th>
                <th class="border-0">Note</th>
                <th class="border-0">Creator Pro</th>
                <th class="border-0">Parent Category</th>
                <th class="border-0">Category</th>
                <th class="border-0">Intetion</th>
                <th class="border-0">ICD</th>
                <th class="border-0"></th>                
            </tr>
        </thead>
        <tbody>
            @foreach($points as $point)
            <tr>
                <td>{{ friendly_date($point->created_at) }}</td>
                <td>
                    <a native target="_blank" href="{{route('patients.view.dashboard', $point->client)}}">
                        {{$point->client->displayName()}}
                    </a>
                </td>
                <td>
                    @if($point->note)
                    <a native target="_blank"
                        href="/patients/view/{{ $point->note->client->uid }}/notes/view/{{ $point->note->uid }}">
                        <b>{{ friendly_date_time($point->note->effective_dateest, false) }}</b>
                    </a>
                    @endif
                </td>
                <td>
                    {{ $point->creatorPro->displayName() }}
                </td>
                <td>{{ $point->parent_category }}</td>
                <td>{{ $point->category }}</td>
                <td>{{ $point->intention }}</td>
                <td>{{ $point->icd }}</td>
                <td>
                    @include('app.admin.points.record-details')
                </td>
            </tr>
            @endforeach
        </tbody>
    </table>
</div>
<div class="px-3 pt-3 d-flex align-items-center">
    {{$points->withQueryString()->links()}}
    <div class="ml-4 mb-3">Showing <b>{{$points->firstItem()}}</b> to <b>{{$points->lastItem()}}</b> (page {{$points->currentPage()}}) of <b>{{$points->total()}}</b> points</div>
</div>