From 52a6935d0705b28f3ad111340cb5bd2e8d9a701f Mon Sep 17 00:00:00 2001 From: Khafid Prayoga Date: Mon, 8 Dec 2025 12:19:14 +0700 Subject: [PATCH] mbois gak rek? --- .../app/action-report/entry-form.vue | 468 ++++++++++++++++++ .../app/action-report/fields/fill-notes.vue | 65 +++ .../app/action-report/fields/index.ts | 10 + .../app/action-report/fields/radio-bloods.vue | 101 ++++ .../action-report/fields/select-billing.vue | 68 +++ .../fields/select-birth-place.vue | 71 +++ .../fields/select-birth-type.vue | 67 +++ .../fields/select-operation-system.vue | 69 +++ .../fields/select-operation-type.vue | 69 +++ .../action-report/fields/select-specimen.vue | 69 +++ .../fields/select-surgery-counter.vue | 67 +++ .../fields/select-surgery-type.vue | 69 +++ .../app/action-report/list-history.cfg.ts | 88 ++++ .../app/action-report/list-history.vue | 39 ++ app/components/app/action-report/list.cfg.ts | 89 ++++ app/components/app/action-report/list.vue | 39 ++ app/components/app/action-report/preview.vue | 166 +++++++ app/components/app/action-report/sample.ts | 54 ++ .../{entry-form.vue => entry.vue} | 68 +-- .../assessment-education/list-history.cfg.ts | 75 +++ .../app/assessment-education/list-history.vue | 39 ++ .../app/assessment-education/list.cfg.ts | 75 +++ .../app/assessment-education/list.vue | 39 ++ .../app/assessment-education/sample.ts | 54 ++ app/components/app/doctor/fields/index.ts | 1 + .../app/doctor/fields/select-doctor.vue | 72 +++ .../content/action-report/entry.vue | 34 ++ app/components/content/action-report/form.vue | 82 +++ app/components/content/action-report/list.vue | 276 +++++++++++ .../content/action-report/sample.ts | 68 +++ app/components/content/action-report/view.vue | 67 +++ .../content/assessment-education/add.vue | 61 --- .../content/assessment-education/entry.vue | 34 ++ .../content/assessment-education/form.vue | 74 +++ .../content/assessment-education/list.vue | 276 +++++++++++ .../content/assessment-education/sample.ts | 68 +++ .../content/assessment-education/view.vue | 67 +++ app/handlers/encounter-init.handler.ts | 115 ++--- app/models/_base.ts | 5 +- app/models/doctor.ts | 10 +- app/models/edu-assessment.ts | 41 -- app/models/encounter.ts | 2 +- app/models/nurse.ts | 2 - app/models/person.ts | 19 +- app/schemas/action-report.schema.ts | 121 +++++ app/schemas/assessment-education.ts | 83 ---- app/schemas/encounter.schema.ts | 5 +- 47 files changed, 3304 insertions(+), 297 deletions(-) create mode 100644 app/components/app/action-report/entry-form.vue create mode 100644 app/components/app/action-report/fields/fill-notes.vue create mode 100644 app/components/app/action-report/fields/index.ts create mode 100644 app/components/app/action-report/fields/radio-bloods.vue create mode 100644 app/components/app/action-report/fields/select-billing.vue create mode 100644 app/components/app/action-report/fields/select-birth-place.vue create mode 100644 app/components/app/action-report/fields/select-birth-type.vue create mode 100644 app/components/app/action-report/fields/select-operation-system.vue create mode 100644 app/components/app/action-report/fields/select-operation-type.vue create mode 100644 app/components/app/action-report/fields/select-specimen.vue create mode 100644 app/components/app/action-report/fields/select-surgery-counter.vue create mode 100644 app/components/app/action-report/fields/select-surgery-type.vue create mode 100644 app/components/app/action-report/list-history.cfg.ts create mode 100644 app/components/app/action-report/list-history.vue create mode 100644 app/components/app/action-report/list.cfg.ts create mode 100644 app/components/app/action-report/list.vue create mode 100644 app/components/app/action-report/preview.vue create mode 100644 app/components/app/action-report/sample.ts rename app/components/app/assessment-education/{entry-form.vue => entry.vue} (83%) create mode 100644 app/components/app/assessment-education/list-history.cfg.ts create mode 100644 app/components/app/assessment-education/list-history.vue create mode 100644 app/components/app/assessment-education/list.cfg.ts create mode 100644 app/components/app/assessment-education/list.vue create mode 100644 app/components/app/assessment-education/sample.ts create mode 100644 app/components/app/doctor/fields/index.ts create mode 100644 app/components/app/doctor/fields/select-doctor.vue create mode 100644 app/components/content/action-report/entry.vue create mode 100644 app/components/content/action-report/form.vue create mode 100644 app/components/content/action-report/list.vue create mode 100644 app/components/content/action-report/sample.ts create mode 100644 app/components/content/action-report/view.vue delete mode 100644 app/components/content/assessment-education/add.vue create mode 100644 app/components/content/assessment-education/entry.vue create mode 100644 app/components/content/assessment-education/form.vue create mode 100644 app/components/content/assessment-education/list.vue create mode 100644 app/components/content/assessment-education/sample.ts create mode 100644 app/components/content/assessment-education/view.vue delete mode 100644 app/models/edu-assessment.ts create mode 100644 app/schemas/action-report.schema.ts delete mode 100644 app/schemas/assessment-education.ts diff --git a/app/components/app/action-report/entry-form.vue b/app/components/app/action-report/entry-form.vue new file mode 100644 index 00000000..2479e1c7 --- /dev/null +++ b/app/components/app/action-report/entry-form.vue @@ -0,0 +1,468 @@ + + + diff --git a/app/components/app/action-report/fields/fill-notes.vue b/app/components/app/action-report/fields/fill-notes.vue new file mode 100644 index 00000000..41c948c5 --- /dev/null +++ b/app/components/app/action-report/fields/fill-notes.vue @@ -0,0 +1,65 @@ + + diff --git a/app/components/app/action-report/fields/index.ts b/app/components/app/action-report/fields/index.ts new file mode 100644 index 00000000..ea1a0e72 --- /dev/null +++ b/app/components/app/action-report/fields/index.ts @@ -0,0 +1,10 @@ +export { default as FillNotes } from './fill-notes.vue' +export { default as RadioBloods } from './radio-bloods.vue' +export { default as SelectBilling } from './select-billing.vue' +export { default as SelectBirthPlace } from './select-birth-place.vue' +export { default as SelectBirthType } from './select-birth-type.vue' +export { default as SelectOperationSystem } from './select-operation-system.vue' +export { default as SelectOperationType } from './select-operation-type.vue' +export { default as SelectSpecimen } from './select-specimen.vue' +export { default as SelectSurgeryCounter } from './select-surgery-counter.vue' +export { default as SelectSurgeryType } from './select-surgery-type.vue' diff --git a/app/components/app/action-report/fields/radio-bloods.vue b/app/components/app/action-report/fields/radio-bloods.vue new file mode 100644 index 00000000..9bdaa187 --- /dev/null +++ b/app/components/app/action-report/fields/radio-bloods.vue @@ -0,0 +1,101 @@ + + + diff --git a/app/components/app/action-report/fields/select-billing.vue b/app/components/app/action-report/fields/select-billing.vue new file mode 100644 index 00000000..f8df074e --- /dev/null +++ b/app/components/app/action-report/fields/select-billing.vue @@ -0,0 +1,68 @@ + + + diff --git a/app/components/app/action-report/fields/select-birth-place.vue b/app/components/app/action-report/fields/select-birth-place.vue new file mode 100644 index 00000000..b2314129 --- /dev/null +++ b/app/components/app/action-report/fields/select-birth-place.vue @@ -0,0 +1,71 @@ + + + diff --git a/app/components/app/action-report/fields/select-birth-type.vue b/app/components/app/action-report/fields/select-birth-type.vue new file mode 100644 index 00000000..537e8282 --- /dev/null +++ b/app/components/app/action-report/fields/select-birth-type.vue @@ -0,0 +1,67 @@ + + + diff --git a/app/components/app/action-report/fields/select-operation-system.vue b/app/components/app/action-report/fields/select-operation-system.vue new file mode 100644 index 00000000..bae300b2 --- /dev/null +++ b/app/components/app/action-report/fields/select-operation-system.vue @@ -0,0 +1,69 @@ + + + diff --git a/app/components/app/action-report/fields/select-operation-type.vue b/app/components/app/action-report/fields/select-operation-type.vue new file mode 100644 index 00000000..e05a4196 --- /dev/null +++ b/app/components/app/action-report/fields/select-operation-type.vue @@ -0,0 +1,69 @@ + + + diff --git a/app/components/app/action-report/fields/select-specimen.vue b/app/components/app/action-report/fields/select-specimen.vue new file mode 100644 index 00000000..9be2bb93 --- /dev/null +++ b/app/components/app/action-report/fields/select-specimen.vue @@ -0,0 +1,69 @@ + + + diff --git a/app/components/app/action-report/fields/select-surgery-counter.vue b/app/components/app/action-report/fields/select-surgery-counter.vue new file mode 100644 index 00000000..2c682529 --- /dev/null +++ b/app/components/app/action-report/fields/select-surgery-counter.vue @@ -0,0 +1,67 @@ + + + diff --git a/app/components/app/action-report/fields/select-surgery-type.vue b/app/components/app/action-report/fields/select-surgery-type.vue new file mode 100644 index 00000000..2c59438a --- /dev/null +++ b/app/components/app/action-report/fields/select-surgery-type.vue @@ -0,0 +1,69 @@ + + + diff --git a/app/components/app/action-report/list-history.cfg.ts b/app/components/app/action-report/list-history.cfg.ts new file mode 100644 index 00000000..d943bc7d --- /dev/null +++ b/app/components/app/action-report/list-history.cfg.ts @@ -0,0 +1,88 @@ +import { defineAsyncComponent } from 'vue' + +import { format } from 'date-fns' +import { id } from 'date-fns/locale' + +import type { Config, RecComponent } from '~/components/pub/my-ui/data-table' +import type { ActionReportData } from '~/components/app/action-report/sample' +const action = defineAsyncComponent(() => import('~/components/pub/my-ui/data/dropdown-action-d.vue')) + +export const config: Config = { + cols: [ + { width: 120 }, + { width: 120 }, + { width: 120 }, + { width: 120 }, + { width: 120 }, + { width: 120 }, + { width: 120 }, + { width: 50 }, + ], + + headers: [ + [ + { label: 'TANGGAL LAPORAN' }, + { label: 'DPJP' }, + { label: 'OPERATOR' }, + { label: 'TANGGAL PEMBEDAHAN' }, + { label: 'JENIS OPERASI' }, + { label: 'KODE BILLING' }, + { label: 'SISTEM OPERASI' }, + { label: 'AKSI' }, + ], + ], + + keys: ['reportAt', 'dpjp', 'operator', 'operationAt', 'operationType', 'billing', 'system', 'action'], + + delKeyNames: [ + { key: 'code', label: 'Kode' }, + { key: 'name', label: 'Nama' }, + ], + + parses: { + reportAt: (rec: unknown): unknown => { + const attr = (rec as ActionReportData).reportAt + const result = format(new Date(attr), 'd MMMM yyyy, HH:mm', { locale: id }) + + return result + }, + operationAt: (rec: unknown): unknown => { + const attr = (rec as ActionReportData).operationAt + const result = format(new Date(attr), 'd MMMM yyyy', { locale: id }) + + return result + }, + system: (rec: unknown): unknown => { + return 'Cito' + }, + operator: (rec: unknown): unknown => { + return 'dr. Dewi Arum Sawitri, Sp.An' + }, + billing: (rec: unknown): unknown => { + return 'General' + }, + operationType: (rec: unknown): unknown => { + return 'Besar' + }, + dpjp: (rec: unknown): unknown => { + return 'dr. Irwansyah Kurniawan Sp.Bo' + }, + parent: (rec: unknown): unknown => { + const recX = rec as any + return recX.parent?.name || '-' + }, + }, + + components: { + action(rec, idx) { + const res: RecComponent = { + idx, + rec: rec as object, + component: action, + } + return res + }, + }, + + htmls: {}, +} diff --git a/app/components/app/action-report/list-history.vue b/app/components/app/action-report/list-history.vue new file mode 100644 index 00000000..6ad7dd81 --- /dev/null +++ b/app/components/app/action-report/list-history.vue @@ -0,0 +1,39 @@ + + + diff --git a/app/components/app/action-report/list.cfg.ts b/app/components/app/action-report/list.cfg.ts new file mode 100644 index 00000000..13a78728 --- /dev/null +++ b/app/components/app/action-report/list.cfg.ts @@ -0,0 +1,89 @@ +import { defineAsyncComponent } from 'vue' + +import { format } from 'date-fns' +import { id } from 'date-fns/locale' + +import type { Config, RecComponent } from '~/components/pub/my-ui/data-table' +import type { ActionReportData } from '~/components/app/action-report/sample' +const action = defineAsyncComponent(() => import('~/components/pub/my-ui/data/dropdown-action-dud.vue')) + +export const config: Config = { + cols: [ + { width: 120 }, + { width: 120 }, + { width: 120 }, + { width: 120 }, + { width: 120 }, + { width: 120 }, + { width: 120 }, + { width: 50 }, + ], + + headers: [ + [ + { label: 'TANGGAL LAPORAN' }, + { label: 'DPJP' }, + { label: 'OPERATOR' }, + { label: 'TANGGAL PEMBEDAHAN' }, + { label: 'JENIS OPERASI' }, + { label: 'KODE BILLING' }, + { label: 'SISTEM OPERASI' }, + { label: 'AKSI' }, + ], + ], + + keys: ['reportAt', 'dpjp', 'operator', 'operationAt', 'operationType', 'billing', 'system', 'action'], + + delKeyNames: [ + { key: 'id', label: 'ID' }, + { key: 'dokter', label: 'Dokter' }, + { key: 'reportAt', label: 'Tanggal Laporan' }, + ], + + parses: { + reportAt: (rec: unknown): unknown => { + const attr = (rec as ActionReportData).reportAt + const result = format(new Date(attr), 'd MMMM yyyy, HH:mm', { locale: id }) + + return result + }, + operationAt: (rec: unknown): unknown => { + const attr = (rec as ActionReportData).operationAt + const result = format(new Date(attr), 'd MMMM yyyy', { locale: id }) + + return result + }, + system: (rec: unknown): unknown => { + return 'Cito' + }, + operator: (rec: unknown): unknown => { + return 'dr. Dewi Arum Sawitri, Sp.An' + }, + billing: (rec: unknown): unknown => { + return 'General' + }, + operationType: (rec: unknown): unknown => { + return 'Besar' + }, + dpjp: (rec: unknown): unknown => { + return 'dr. Irwansyah Kurniawan Sp.Bo' + }, + parent: (rec: unknown): unknown => { + const recX = rec as any + return recX.parent?.name || '-' + }, + }, + + components: { + action(rec, idx) { + const res: RecComponent = { + idx, + rec: rec as object, + component: action, + } + return res + }, + }, + + htmls: {}, +} diff --git a/app/components/app/action-report/list.vue b/app/components/app/action-report/list.vue new file mode 100644 index 00000000..6ad7dd81 --- /dev/null +++ b/app/components/app/action-report/list.vue @@ -0,0 +1,39 @@ + + + diff --git a/app/components/app/action-report/preview.vue b/app/components/app/action-report/preview.vue new file mode 100644 index 00000000..fa113333 --- /dev/null +++ b/app/components/app/action-report/preview.vue @@ -0,0 +1,166 @@ + + + + + diff --git a/app/components/app/action-report/sample.ts b/app/components/app/action-report/sample.ts new file mode 100644 index 00000000..b067e859 --- /dev/null +++ b/app/components/app/action-report/sample.ts @@ -0,0 +1,54 @@ +import { addWeeks, formatISO } from 'date-fns' + +export type ActionReportData = { + id: number + reportAt: string + operationAt: string + noRm: string + noBill: string + nama: string + jk: string + alamat: string + klinik: string + dokter: string + caraBayar: string + rujukan: string + ketRujukan: string + asal: string +} + +export const sampleRows: ActionReportData[] = [ + { + id: 1, + reportAt: formatISO(addWeeks(new Date(), -1)), + operationAt: formatISO(addWeeks(new Date(), 1)), + noRm: 'RM23311224', + noBill: '-', + nama: 'Ahmad Baidowi', + jk: 'L', + alamat: 'Jl Jaksa Agung S. No. 9', + klinik: 'Penyakit dalam', + dokter: 'Dr. Andreas Sutaji', + caraBayar: 'JKN', + rujukan: 'Faskes BPJS', + ketRujukan: 'RUMAH SAKIT - RS Lawang Medika - Malang', + asal: 'Rawat Jalan Reguler', + }, + { + id: 2, + reportAt: new Date().toISOString(), + operationAt: formatISO(addWeeks(new Date(), 2)), + noRm: 'RM23455667', + noBill: '-', + nama: 'Abraham Sulaiman', + jk: 'L', + alamat: 'Purwantoro, Blimbing', + klinik: 'Penyakit dalam', + dokter: 'Dr. Andreas Sutaji', + caraBayar: 'JKN', + rujukan: 'Faskes BPJS', + ketRujukan: 'RUMAH SAKIT - RS Lawang Medika - Malang', + asal: 'Rawat Jalan Reguler', + }, + // tambahkan lebih banyak baris contoh jika perlu +] diff --git a/app/components/app/assessment-education/entry-form.vue b/app/components/app/assessment-education/entry.vue similarity index 83% rename from app/components/app/assessment-education/entry-form.vue rename to app/components/app/assessment-education/entry.vue index 1c8b3656..33cfa826 100644 --- a/app/components/app/assessment-education/entry-form.vue +++ b/app/components/app/assessment-education/entry.vue @@ -1,13 +1,17 @@ - -