Incomplete Forms These forms are generated and require completion when triggered by specific logic within the initial form
| Type | @foreach ($record->get_pending_forms(true) as $pending_form ) | |
|---|---|---|
| {{$pending_form['form']}} | {{isset($pending_form['form_draft']) ? $pending_form['form_draft'] : '-'}} |
Ignore
@if ($record->created_by->email != 'external@qitech.com' || $pending_form['type'] == 0)
Complete Now
@elseif ($record->created_by->email == 'external@qitech.com' || $pending_form['type'] == 1)
Submit
@endif
|
{{ $taskItem->title ?? '[Task Name goes here]' }}
{{ $taskItem->priority ?? 'No Priority' }} @if ($isOverdue) Overdue @endif{!! $taskItem->description ?? 'No Description' !!}
There are no tasks
All caught up! No tasks assigned at the moment.
{{ $record->form->name }}
Description:
{{ $record->form->note }}
Submitted:
{{ $record->created_at->format('d M Y (D) h:i a') }}
Completed By:
{{ $record->location->trading_name }}
,{{ isset($record->created_by) ? ($record->created_by->first_name . ' ' . $record->created_by->surname) : 'Quick login' }}
Unfortunately, the time period to submit further updates has passed. Please submit another form if you need to provide further information.
@elseif (isset($case) && $case->status == 'closed' && $record->form->allow_update_state != 'open')Case is Closed
@elseThis form does not allow updates. Please submit another form if you need to provide further information.
@endif-
@foreach ($json as $id => $changes)
@php
// Function to extract values
if (!function_exists('extractValues')) {
function extractValues($value) {
if (is_array($value) && !empty($value)) {
$flattened = [];
foreach ($value as $item) {
if (is_array($item)) {
if (!empty($item['vtm']['vtm_string'])) {
$flattened[] = $item['vtm']['vtm_string'];
}
if (!empty($item['other'])) {
$flattened[] = $item['other'];
}
} else {
$flattened[] = (string) $item;
}
}
return !empty($flattened) ? implode(', ', $flattened) : null;
}
return !empty($value) ? (string) $value : null;
}
}
// Extract values
$original_value = extractValues($changes['original']['value'] ?? null);
$modified_value = extractValues($changes['modified']['value'] ?? null);
// Skip rendering if both values are empty
if (empty($original_value) && empty($modified_value)) {
continue;
}
// Get details or fallback
$details = !empty($original_value) ? $record->get_question_details_by_id($id, $modification->parent_record_id, $original_value) : null;
$modified_details = !empty($modified_value) ? $record->get_question_details_by_id($id, $modification->parent_record_id, $modified_value) : null;
if (empty($details) && !empty($original_value)) {
$details = $original_value;
}
if (empty($modified_details) && !empty($modified_value)) {
$modified_details = $modified_value;
}
// Format results
$result = is_array($details) && !empty($details) ? implode(', ', array_map('strval', $details)) : ($details ?? 'N/A');
$modified_result = is_array($modified_details) && !empty($modified_details) ? implode(', ', array_map('strval', $modified_details)) : ($modified_details ?? 'N/A');
@endphp
-
Question: {{ $changes['original']['label'] ?? 'Unknown' }}
Response: {{ $result ?? 'N/A' }} → {{ $modified_result ?? 'N/A' }}
@endforeach
No modifications!
@endifDate
{{ $feedback->created_at->format('d/m/Y') }}
Reported
@isset($case_ids) @foreach ($case_ids as $case_id) @php $feedback_case = HeadOfficeCase::find($case_id)->first(); @endphp{{ $feedback_case->created_at->format('d/m/Y') }}
{{ $feedback_case->incident_type }}
{{ $feedback_case->location_name }}
Feedback by {{ $feedback->HeadOffice->name() }}
{!! isset($feedback->feedback_location) ? $feedback->feedback_location : $feedback->HeadOffice->name() . ' ' . "did'nt provided any feedback" !!}
No Feedbacks at the moment 🙂!
@endifDeletion Message:
{{$record->lfpse_deletes->message}}
| Sr# | @foreach ($record->LfpseSubmissions as $sr => $s)Record {{$sr + 1}} | @endforeach
| LFPSE ID | @foreach ($record->LfpseSubmissions as $s){{$s->reference_id}} | @endforeach
| Type | @php $data_objects = collect($data_objects); $FormType = $data_objects->firstWhere('label', 'What kind of event do you want to record?')['value']; @endphp{{$FormType == 'Incident - Something unexpected or unintended has happened, or failed to happen, that could have or did lead to patient harm for one or more person(s) receiving healthcare.' ? 'Incident' : "Good Care"}} |
| Version | @foreach ($record->LfpseSubmissions as $s){{isset($s->version) ? $s->version : '6'}} | @endforeach
| Outcome | @foreach ($record->LfpseSubmissions as $s){{$s->outcome_type_string}} | @endforeach
| Psychological Harm | {{$data_objects->firstWhere('label', 'To what extent was the patient psychologically harmed in this incident?')['value']}} |
| Physical Harm | {{$data_objects->firstWhere('label', 'To what extent was the patient physically harmed (including pain) in this incident?')['value']}} |
| Remarks | @foreach ($record->LfpseSubmissions as $s){{$s->remarks}} | @endforeach
| Date | @foreach ($record->LfpseSubmissions as $s){{$s->created_at->format('d M Y (D) h:i a')}} | @endforeach
| fsaf | |
| fsaf | |
| LFPSE ID | @foreach ($lfpseRec->LfpseSubmissions as $s){{$s->reference_id}} | @endforeach
| Actual ID | @foreach ($lfpseRec->LfpseSubmissions as $s){{$s->lfpse_id}} | @endforeach
| Version | @foreach ($lfpseRec->LfpseSubmissions as $s){{isset($s->version) ? $s->version : '6'}} | @endforeach
| Outcome | @foreach ($lfpseRec->LfpseSubmissions as $s){{$s->outcome_type_string}} | @endforeach
| Psychological Harm | {{$data_objects->firstWhere('label', 'To what extent was the patient physically harmed (including pain) in this incident?')['value']}} |
| Physical Harm | {{ $data_objects->firstWhere('label', 'To what extent was the patient physically harmed (including pain) in this incident?')['value']}} |
| Remarks | @foreach ($lfpseRec->LfpseSubmissions as $s){{$s->remarks}} | @endforeach
| Date | @foreach ($lfpseRec->LfpseSubmissions as $s){{$s->created_at->format('d M Y (D) h:i a')}} | @endforeach