@include('layout.header')
@include('layout.navbar') @include('layout.breadscrum')
@include('layout.sidebar')

{{__('sample.table_title')}}

{{__('sample.filter_all')}} @if(\App\Http\Controllers\Helper\GlobalController::user_can(Auth::user()->role_id, ['create_sample'])) {{__('general.btn_add_new')}} @endif

{{-- --}} {{-- --}} @foreach($samples as $k=>$sample) {{-- --}} @endforeach
{{__('sample.table_no')}} {{__('sample.table_action')}} {{__('sample.table_patient_name')}} {{__('patient.form_age')}} {{__('patient.table_sex')}} {{__('patient.table_phon')}} {{__('ប្រភពសំណាក')}}{{__('sample.physician_name')}}{{__('sample.table_sample_number')}} {{__('sample.table_patient_code')}} {{__('sample.table_collected_date')}} {{__('sample.table_status')}}{{__('sample.table_action')}}
{{($k+1) + (($_GET['page'] ?? 1) * 20) - 20}}
@if(\App\Http\Controllers\Helper\GlobalController::user_can(Auth::user()->role_id, ['add_result','update_result'])) @endif @if(\App\Http\Controllers\Helper\GlobalController::user_can(Auth::user()->role_id, ['update_sample'])) @endif @if(\App\Http\Controllers\Helper\GlobalController::user_can(Auth::user()->role_id, ['view_result'])) @endif @if($sample->record_status_id==0) @else @if(\App\Http\Controllers\Helper\GlobalController::user_can(Auth::user()->role_id, ['delete_sample'])) @endif @endif
{{$sample->patient->name_en}} {{\App\Helpers\Helpers::getAge($sample->patient->dob, date('d-m-Y h:i A',strtotime($sample->collected_date)))}} {{$sample->patient->gender == 1 ? 'M' : 'F'}} {{$sample->patient->phone_number}} {{@$sample->sample_source->name_en}}{{@$sample->physician->name_en}}{{$sample->sample_number}} {{$sample->patient->patient_uuid}} {{date('d-m-Y h:i A',strtotime($sample->collected_date))}} {{-- --}}
{!! $samples->appends($_GET)->links('pagination.custom') !!}
@include('layout.footer')
@include('layout.common_script')