feat: add supplementary insurance select to patient record info form

The «اطلاعات پرونده» form only exposed basic insurance («نوع بیمه»). Add a
«بیمه تکمیلی» select next to it, wired to the supplementary insurances from
insurance-pricing. Backend PATCH /api/v1/patient/{uuid} already accepts
supplementary_insurance_id (UserProfile entity + controller) — frontend-only:
schema field, form select, profileToFormValues/formValuesToPayload mapping,
PatientProfileUpdate type, and the supplementary option passed from both the
case-file info tab (PatientDetailPage) and MyPatientsPage.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
hamed
2026-07-16 10:59:23 +03:30
co-authored by Claude Opus 4.8
parent 8feaf0f22a
commit 46ee24d101
8 changed files with 24 additions and 3 deletions
+2
View File
@@ -42,6 +42,7 @@ export function profileToFormValues(p: PatientProfile | null): PatientFormValues
fathers_name: p?.fathers_name ?? '',
marital_status: p?.marital_status ?? null,
basic_insurance_id: p?.basic_insurance_id ?? null,
supplementary_insurance_id: p?.supplementary_insurance_id ?? null,
field_of_study: p?.field_of_study ?? '',
education: p?.education ?? null,
job: p?.job ?? '',
@@ -70,6 +71,7 @@ export function formValuesToPayload(v: PatientFormValues): PatientProfileUpdate
field_of_study: v.field_of_study,
job: v.job,
basic_insurance_id: num(v.basic_insurance_id),
supplementary_insurance_id: num(v.supplementary_insurance_id),
province_id: num(v.province_id),
city_id: num(v.city_id),
home_phone: v.home_phone,