@include('themes.backend.partials.module_title_breadcrumb', [
'module_name' => $pageDataAtrArr['module_name'],
])
@include('themes.backend.partials.page_title', [
'title' => $pageDataAtrArr['title'],
])
@if ($errors->any())
Please correct the highlighted fields and try again.
@endif
@php
$patientLabelClass = 'np-label';
$fieldsById = $form->fields->keyBy('id');
$requestFieldName = fn($field) => \App\Utilities\EnquiryUtility::getFieldRequestKey($form, $field);
$fieldValue = fn($name, $default = '') => old($name, $fieldValues[$name] ?? $default);
$radioChecked = fn($name, $value) => (string) $fieldValue($name) === (string) $value ? 'checked' : '';
$checkboxChecked = function ($name, $value) use ($fieldValue) {
$rawValue = $fieldValue($name);
$values = is_array($rawValue)
? $rawValue
: array_map('trim', explode(',', (string) $rawValue));
return in_array((string) $value, array_map('strval', $values), true) ? 'checked' : '';
};
$optionValues = fn($field) => \App\Lib\Core\Core::parseJson($field->options) ?? [];
$signatureFileName = $fieldValue('signature');
$signatureUrl = $signatureFileName ? $mediaFolder . $signatureFileName : '';
$patientTextFields = [
['key' => 'date_of_birth', 'col' => 'np-col-4', 'type' => 'date'],
['key' => 'street_address', 'col' => 'np-col-8', 'type' => 'text'],
['key' => 'city', 'col' => 'np-col-4', 'type' => 'text'],
['key' => 'province', 'col' => 'np-col-4', 'type' => 'text'],
['key' => 'postal_code', 'col' => 'np-col-4', 'type' => 'text'],
['key' => 'email_address', 'col' => 'np-col-4', 'type' => 'email'],
['key' => 'home_phone', 'col' => 'np-col-6', 'type' => 'tel'],
['key' => 'cell_phone', 'col' => 'np-col-6', 'type' => 'tel'],
['key' => 'cccupation', 'col' => 'np-col-6', 'type' => 'text'],
['key' => 'employed_by', 'col' => 'np-col-6', 'type' => 'text'],
];
$insuranceFields = [
['key' => 'insurance_company', 'col' => 'np-col-4', 'type' => 'text'],
['key' => 'policy_no', 'col' => 'np-col-4', 'type' => 'text'],
['key' => 'certificate_no', 'col' => 'np-col-4', 'type' => 'text'],
['key' => 'family_physician', 'col' => 'np-col-6', 'type' => 'text'],
['key' => 'physician_phone', 'col' => 'np-col-6', 'type' => 'tel'],
['key' => 'previous_dentist', 'col' => 'np-col-6', 'type' => 'text'],
['key' => 'previous_dentist_phone', 'col' => 'np-col-6', 'type' => 'tel'],
['key' => 'referral_credit', 'col' => 'np-col-12', 'type' => 'text'],
];
$emergencyFields = ['en_contact_name', 'en_relationship', 'en_address', 'en_phone_number'];
$medicalRows = [
['id' => 53, 'type' => 'date'],
['id' => 54, 'extra' => 'cup_care_specify'],
['id' => 56],
['id' => 57],
['id' => 58, 'extra' => 'drink_alcohol_specify'],
['id' => 60],
['id' => 61, 'extra' => 'herbal_substances_specify'],
['id' => 63, 'extra' => 'any_medications_specify'],
['id' => 65, 'extra' => 'prolonged_medication_specify'],
['id' => 67],
['id' => 68, 'extra' => 'any_surgery_specify'],
['id' => 70],
['id' => 71],
['id' => 72, 'extra' => 'pregnant_weeks'],
];
$medicalDrugReactionRows = [['id' => 76, 'extra' => 'adverse_reactions_specify']];
$medicalPostConditionRows = [
['id' => 79],
['id' => 80, 'extra' => 'anything_else_know_specify'],
['id' => 82],
['id' => 83, 'extra' => 'anything_about_health_specify'],
['id' => 85],
];
$dentalRows = [
['id' => 86, 'type' => 'date'],
['id' => 87, 'type' => 'date'],
['id' => 88, 'type' => 'date'],
['id' => 89],
['id' => 90, 'type' => 'text'],
['id' => 91, 'type' => 'text'],
['id' => 92],
['id' => 93],
['id' => 94],
['id' => 95],
['id' => 96],
['id' => 97, 'type' => 'text'],
['id' => 98, 'type' => 'text'],
['id' => 99, 'type' => 'text'],
['id' => 100, 'extra' => 'any_discomfort_specify'],
];
$dentalFollowUpRows = [
['id' => 103],
['id' => 104],
['id' => 105],
['id' => 106],
['id' => 107],
['id' => 108],
['id' => 109],
['id' => 110],
['id' => 111],
['id' => 112],
];
$medicalReactionCheckboxGroups = [
['field' => $fieldsById->get(74), 'cols' => 'cols-4'],
['field' => $fieldsById->get(75), 'cols' => 'cols-3'],
];
$medicalConditionCheckboxGroups = [
['field' => $fieldsById->get(78), 'cols' => 'cols-3'],
];
$dentalCheckboxGroups = [['field' => $fieldsById->get(102), 'cols' => 'cols-3']];
@endphp
{{ $locationModel->title }}
{!! nl2br(e($locationModel->address)) !!}
{{ $locationModel->email }}
{{ $locationModel->phone }}