Complete Dentistry commercial suite with PMS depth.
Deploy Ladill Care / deploy (push) Successful in 31s

Add plan lifecycle, visit stages with chair/recovery points, primary dentition charting, imaging void, revenue reports, perio exams, lab cases, and recalls.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
isaacclad
2026-07-18 17:11:15 +00:00
co-authored by Cursor
parent e227f8705f
commit ce782382c5
37 changed files with 2458 additions and 204 deletions
+56 -7
View File
@@ -207,13 +207,16 @@ class CareQueueProvisioner
CareQueueContexts::CONSULTATION,
$priorByKey,
),
CareQueueContexts::isSpecialty($context) => $this->practitionerPoints(
$organization,
$branch,
$context,
$priorByKey,
data_get($organization->settings, "specialty_module_provisioning.{$context}.department_ids", []),
),
CareQueueContexts::isSpecialty($context) => array_values(array_merge(
$this->practitionerPoints(
$organization,
$branch,
$context,
$priorByKey,
data_get($organization->settings, "specialty_module_provisioning.{$context}.department_ids", []),
),
$this->specialtyStagePoints($organization, $branch, $context, $priorByKey),
)),
$context === CareQueueContexts::TRIAGE => $this->memberRolePoints(
$organization,
$branch,
@@ -276,6 +279,52 @@ class CareQueueProvisioner
return $points;
}
/**
* Fixed stage points for specialty modules that define distinct queue_point values
* (e.g. dentistry waiting / chair / recovery).
*
* @param \Illuminate\Support\Collection<string, array<string, mixed>> $priorByKey
* @return list<array<string, mixed>>
*/
protected function specialtyStagePoints(
Organization $organization,
Branch $branch,
string $context,
$priorByKey,
): array {
if ($context !== 'dentistry') {
return [];
}
$stages = app(SpecialtyShellService::class)->stages($context);
$seen = [];
$points = [];
foreach ($stages as $stage) {
$queuePoint = $stage['queue_point'] ?? null;
if (! is_string($queuePoint) || $queuePoint === '' || isset($seen[$queuePoint])) {
continue;
}
$seen[$queuePoint] = true;
$key = CareQueueContexts::pointExternalKey($context, $branch->id, 'stage', $queuePoint);
$prior = $priorByKey->get($key, []);
$label = (string) ($stage['label'] ?? ucfirst($queuePoint));
$points[] = [
'kind' => 'stage',
'stage' => $queuePoint,
'ref_id' => 0,
'name' => $label,
'destination' => $label,
'staff_ref' => null,
'staff_display_name' => null,
'external_key' => $key,
'counter_uuid' => $prior['counter_uuid'] ?? null,
'synced' => false,
];
}
return $points;
}
/**
* @param list<int|string>|null $departmentIds
* @param \Illuminate\Support\Collection<string, array<string, mixed>> $priorByKey