Deploy Ladill Care / deploy (push) Failing after 36s
Replace placeholder clinical forms with patient-level FDI charting, multi-visit plans, procedure-to-bill linking, imaging, reports, and demo seed data. Co-authored-by: Cursor <cursoragent@cursor.com>
102 lines
5.2 KiB
PHP
102 lines
5.2 KiB
PHP
@php
|
|
$teethMap = $dentalTeethMap ?? [];
|
|
$selected = old('tooth_code', request('tooth', '16'));
|
|
$selectedData = $teethMap[$selected] ?? ['status' => 'present', 'surfaces' => [], 'conditions' => [], 'notes' => null];
|
|
@endphp
|
|
|
|
<section class="rounded-2xl border border-slate-200 bg-white p-5">
|
|
<div class="flex flex-wrap items-start justify-between gap-3">
|
|
<div>
|
|
<h3 class="text-sm font-semibold text-slate-900">Odontogram (FDI)</h3>
|
|
<p class="mt-0.5 text-xs text-slate-500">Click a tooth to chart status, surfaces, and conditions. Changes are saved to the patient chart.</p>
|
|
</div>
|
|
<a href="{{ route('care.specialty.dentistry.print', $workspaceVisit) }}" target="_blank" class="text-sm font-medium text-indigo-600">Print chart / plan</a>
|
|
</div>
|
|
|
|
<div class="mt-4 space-y-2">
|
|
@foreach (['upper' => 'Upper', 'lower' => 'Lower'] as $rowKey => $rowLabel)
|
|
<div>
|
|
<p class="mb-1 text-[10px] font-semibold uppercase tracking-wide text-slate-400">{{ $rowLabel }}</p>
|
|
<div class="flex flex-wrap gap-1">
|
|
@foreach (($dentalRows[$rowKey] ?? []) as $code)
|
|
@php
|
|
$t = $teethMap[$code] ?? ['status' => 'present', 'conditions' => []];
|
|
$hasFinding = ($t['status'] ?? 'present') !== 'present' || ! empty($t['conditions']);
|
|
@endphp
|
|
<a
|
|
href="{{ route('care.specialty.workspace', ['module' => 'dentistry', 'visit' => $workspaceVisit, 'tab' => 'odontogram', 'tooth' => $code]) }}"
|
|
@class([
|
|
'inline-flex h-10 w-9 items-center justify-center rounded-lg border text-xs font-semibold tabular-nums transition',
|
|
'border-indigo-400 bg-indigo-50 text-indigo-900 ring-2 ring-indigo-400' => $code === $selected,
|
|
'border-amber-300 bg-amber-50 text-amber-900' => $hasFinding && $code !== $selected,
|
|
'border-slate-200 bg-slate-50 text-slate-700 hover:border-slate-300' => ! $hasFinding && $code !== $selected,
|
|
])
|
|
title="Tooth {{ $code }}"
|
|
>
|
|
{{ $code }}
|
|
</a>
|
|
@endforeach
|
|
</div>
|
|
</div>
|
|
@endforeach
|
|
</div>
|
|
|
|
<form
|
|
method="POST"
|
|
action="{{ route('care.specialty.dentistry.tooth', $workspaceVisit) }}"
|
|
class="mt-6 grid gap-4 border-t border-slate-100 pt-4 sm:grid-cols-2"
|
|
>
|
|
@csrf
|
|
<input type="hidden" name="tooth_code" value="{{ $selected }}">
|
|
|
|
<div>
|
|
<label class="block text-xs font-medium text-slate-600">Selected tooth</label>
|
|
<p class="mt-1 text-lg font-semibold tabular-nums text-slate-900">{{ $selected }}</p>
|
|
</div>
|
|
|
|
<div>
|
|
<label class="block text-xs font-medium text-slate-600">Status</label>
|
|
<select name="status" class="mt-1 w-full rounded-xl border border-slate-200 px-3 py-2 text-sm">
|
|
@foreach ($dentalStatuses as $value => $label)
|
|
<option value="{{ $value }}" @selected(($selectedData['status'] ?? 'present') === $value)>{{ $label }}</option>
|
|
@endforeach
|
|
</select>
|
|
</div>
|
|
|
|
<div class="sm:col-span-2">
|
|
<p class="text-xs font-medium text-slate-600">Surfaces</p>
|
|
<div class="mt-2 flex flex-wrap gap-3">
|
|
@foreach ($dentalSurfaces as $surface)
|
|
<label class="inline-flex items-center gap-1.5 text-sm text-slate-700">
|
|
<input type="checkbox" name="surfaces[]" value="{{ $surface }}" class="rounded border-slate-300 text-indigo-600"
|
|
@checked(in_array($surface, $selectedData['surfaces'] ?? [], true))>
|
|
{{ $surface }}
|
|
</label>
|
|
@endforeach
|
|
</div>
|
|
</div>
|
|
|
|
<div class="sm:col-span-2">
|
|
<p class="text-xs font-medium text-slate-600">Conditions</p>
|
|
<div class="mt-2 flex flex-wrap gap-3">
|
|
@foreach ($dentalConditions as $value => $label)
|
|
<label class="inline-flex items-center gap-1.5 text-sm text-slate-700">
|
|
<input type="checkbox" name="conditions[]" value="{{ $value }}" class="rounded border-slate-300 text-indigo-600"
|
|
@checked(in_array($value, $selectedData['conditions'] ?? [], true))>
|
|
{{ $label }}
|
|
</label>
|
|
@endforeach
|
|
</div>
|
|
</div>
|
|
|
|
<div class="sm:col-span-2">
|
|
<label class="block text-xs font-medium text-slate-600">Notes</label>
|
|
<textarea name="notes" rows="2" class="mt-1 w-full rounded-xl border border-slate-200 px-3 py-2 text-sm">{{ $selectedData['notes'] ?? '' }}</textarea>
|
|
</div>
|
|
|
|
<div class="sm:col-span-2">
|
|
<button type="submit" class="btn-primary">Save tooth</button>
|
|
</div>
|
|
</form>
|
|
</section>
|