improvement: all clinic side ui components related to treatment types updated based on the new real world data.
This commit is contained in:
@@ -7,7 +7,17 @@ export type CatalogTranslationSeed = {
|
||||
label: string;
|
||||
};
|
||||
|
||||
export const TREATMENT_TYPES = [
|
||||
export type TreatmentTypeSeed = {
|
||||
code: string;
|
||||
labDependent: boolean;
|
||||
sortOrder: number;
|
||||
/** Selectable when booking an appointment. Defaults to true. */
|
||||
availableInAppointments?: boolean;
|
||||
/** Selectable as a treatment plan detail. Defaults to true. */
|
||||
availableInTreatment?: boolean;
|
||||
};
|
||||
|
||||
export const TREATMENT_TYPES: readonly TreatmentTypeSeed[] = [
|
||||
{ code: 'restoration', labDependent: false, sortOrder: 1 },
|
||||
{ code: 'specialized_restoration', labDependent: false, sortOrder: 2 },
|
||||
{ code: 'radiography', labDependent: false, sortOrder: 3 },
|
||||
@@ -19,11 +29,23 @@ export const TREATMENT_TYPES = [
|
||||
{ code: 'perio', labDependent: false, sortOrder: 9 },
|
||||
{ code: 'pediatrics', labDependent: false, sortOrder: 10 },
|
||||
{ code: 'extraction', labDependent: false, sortOrder: 11 },
|
||||
{ code: 'clinic_visit', labDependent: false, sortOrder: 12 },
|
||||
// Appointment-only: not real treatment plan details.
|
||||
{
|
||||
code: 'clinic_visit',
|
||||
labDependent: false,
|
||||
sortOrder: 12,
|
||||
availableInTreatment: false,
|
||||
},
|
||||
{
|
||||
code: 'continue_treatment',
|
||||
labDependent: false,
|
||||
sortOrder: 13,
|
||||
availableInTreatment: false,
|
||||
},
|
||||
] as const;
|
||||
|
||||
/** Legacy codes kept for historical rows; hidden from catalog. */
|
||||
export const LEGACY_TREATMENT_TYPES = [
|
||||
export const LEGACY_TREATMENT_TYPES: readonly TreatmentTypeSeed[] = [
|
||||
{ code: 'consultation', labDependent: false, sortOrder: 99 },
|
||||
{ code: 'filling', labDependent: false, sortOrder: 100 },
|
||||
{ code: 'visit', labDependent: false, sortOrder: 101 },
|
||||
@@ -207,7 +229,8 @@ const TREATMENT_LABELS: Record<string, Record<string, string>> = {
|
||||
perio: { en: 'Perio', fa: 'پریو', nl: 'Paro' },
|
||||
pediatrics: { en: 'Pediatrics', fa: 'اطفال', nl: 'Kinderen' },
|
||||
extraction: { en: 'Extraction', fa: 'کشیدن', nl: 'Extractie' },
|
||||
clinic_visit: { en: 'Clinic Visit', fa: 'درمانگاه', nl: 'Kliniekbezoek' },
|
||||
clinic_visit: { en: 'Clinic Visit', fa: 'ویزیت درمانگاه', nl: 'Kliniekbezoek' },
|
||||
continue_treatment: { en: 'Continue Treatment', fa: 'ادامه درمان', nl: 'Behandeling Voortzetten' },
|
||||
consultation: { en: 'Consultation', fa: 'مشاوره', nl: 'Consult' },
|
||||
filling: { en: 'Filling', fa: 'پر کردن', nl: 'Vulling' },
|
||||
visit: { en: 'Visit', fa: 'ویزیت', nl: 'Bezoek' },
|
||||
|
||||
Reference in New Issue
Block a user