item.code === relative.education_code)?.label || '-' }}
- {{ occupationOptions.find((item) => item.code === relative.occupation_code)?.label || relative.occupation_name || '-' }}
+ {{
+ occupationOptions.find((item) => item.code === relative.occupation_code)?.label ||
+ relative.occupation_name ||
+ '-'
+ }}
{{ relative.address || '-' }}
{{ relative.phoneNumber || '-' }}
diff --git a/app/components/content/patient/detail.vue b/app/components/content/patient/detail.vue
index 0ca4cd0d..eb73f2ff 100644
--- a/app/components/content/patient/detail.vue
+++ b/app/components/content/patient/detail.vue
@@ -75,9 +75,6 @@ function handleAction(type: string) {
/>
diff --git a/app/models/person.ts b/app/models/person.ts
index cf27894f..46850ec5 100644
--- a/app/models/person.ts
+++ b/app/models/person.ts
@@ -1,8 +1,9 @@
import { type Base, genBase } from './_base'
+import type { PersonAddress } from './person-address'
+import type { PersonContact } from './person-contact'
+import type { PersonRelative } from './person-relative'
export interface Person extends Base {
- // todo: awaiting approve from stake holder: buat field sapaan
- // todo: adjust field ketika person Balita
name: string
// alias?: string
frontTitle?: string
@@ -26,6 +27,11 @@ export interface Person extends Base {
passportFileUrl?: string
drivingLicenseFileUrl?: string
familyIdentityFileUrl?: string
+
+ // preload data for detail patient
+ addresses?: PersonAddress[] | null
+ contacts?: PersonContact[] | null
+ relatives?: PersonRelative[] | null
}
export function genPerson(): Person {