{{-- @dd($pendingItems) --}} Pending List Pending List
@if ((Auth::check() && Auth::user()->hasRole('DYCHO')) || Auth::user()->hasRole('SFO')) @endif @foreach ($pendingItems as $pro) @php $status_data = $statusdata ->where('service_id', $pro->service_id) ->where('table_id', $pro->id) ->first(); // dd( // $status_data->clerk_forward_status, // $status_data->hod_forward_status, // $status_data->clerk_status, // $status_data->hod_status, // $status_data->deputy_costatus, // ($status_data->clerk_forward_status == 1 || $status_data->hod_forward_status == 1) && ($status_data->clerk_status == 0 && $status_data->hod_status ==0 && $status_data->deputy_costatus ==0 )); @endphp @if ((Auth::check() && Auth::user()->hasRole('DYCHO')) || Auth::user()->hasRole('SFO')) @endif @endforeach
Sr.No Application.No Applicant Name Service ID DateRemarkProcess Status
{{ $loop->iteration }} {{ $pro->application_no }} {{ $user->where('id', $pro->user_id)->first()?->name }} {{ \Illuminate\Support\Str::limit($serviceName->where('service_id', $pro->service_id)->first()?->service_name, 30) }} {{ isset($pro->created_at) ? date('d-m-Y h:i A', strtotime($pro->created_at)) : 'N/A' }} @php $role = Auth::user()->getRoleNames()->first(); $remarkField = $role === 'DYCHO' ? 'clerk_remark' : ($role === 'SFO' ? 'hod_remark' : null); $remark = $remarkField ? $statusdata ->where('service_id', $pro->service_id) ->where('table_id', $pro->id) ->value($remarkField) : null; @endphp {{ $remark ?? '-' }} @if ( $status_data->clerk_status == 0 && $status_data->hod_status == 0 && $status_data->deputy_costatus == 0 && $status_data->deputy_co_forward_status == 1 && !empty($status_data->payment_reciept_document)) Verify Payment Reciept @elseif ( ($status_data->clerk_forward_status == 1 || $status_data->hod_forward_status == 1) && ($status_data->clerk_status == 0 && $status_data->hod_status == 0 && $status_data->deputy_costatus == 0)) Forwading Process @elseif ($status_data->clerk_status == 1 || $status_data->hod_status == 1 || $status_data->deputy_costatus == 1) Approval Process @else -- @endif @if (!empty($currentStatus->payment_reciept_document)) View Payment Reciept @endif {{-- --}} {{-- --}} @if ($pro->status()->where('service_id', $pro->service_id)->first()?->id) View @else - @endif
{{-- --}} {{-- --}}
{{-- --}}