diff --git a/app/assets/svg/wavey-fingerprint.svg b/app/assets/svg/wavey-fingerprint.svg
new file mode 100644
index 00000000..b281297f
--- /dev/null
+++ b/app/assets/svg/wavey-fingerprint.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/app/components/app/device-order-item/entry-form.vue b/app/components/app/device-order-item/entry-form.vue
new file mode 100644
index 00000000..3ae2d200
--- /dev/null
+++ b/app/components/app/device-order-item/entry-form.vue
@@ -0,0 +1,73 @@
+
+
+
+
+
+ Nama
+
+
+
+
+
+ Jumlah
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/app/components/app/device-order-item/list-entry.config.ts b/app/components/app/device-order-item/list-entry.config.ts
index f2f3ef86..d47c4368 100644
--- a/app/components/app/device-order-item/list-entry.config.ts
+++ b/app/components/app/device-order-item/list-entry.config.ts
@@ -1,36 +1,35 @@
import { defineAsyncComponent } from 'vue'
-import type { Config } from '~/components/pub/my-ui/data-table'
-
+import type { Config, RecComponent } from '~/components/pub/my-ui/data-table'
const action = defineAsyncComponent(() => import('~/components/pub/my-ui/data/dropdown-action-ud.vue'))
export const config: Config = {
- cols: [{}, {}, { width: 50 }],
+ cols: [{}, { width: 200 }, { width: 100 }],
headers: [[{ label: 'Nama' }, { label: 'Jumlah' }, { label: '' }]],
- keys: ['name', 'count', 'action'],
+ keys: ['device.name', 'quantity', 'action'],
delKeyNames: [
{ key: 'name', label: 'Nama' },
{ key: 'count', label: 'Jumlah' },
],
- skeletonSize: 10
+ skeletonSize: 10,
// funcParsed: {
// parent: (rec: unknown): unknown => {
// const recX = rec as SmallDetailDto
// return recX.parent?.name || '-'
// },
// },
- // funcComponent: {
- // action(rec: object, idx: any) {
- // const res: RecComponent = {
- // idx,
- // rec: rec as object,
- // component: action,
- // props: {
- // size: 'sm',
- // },
- // }
- // return res
- // },
- // }
+ components: {
+ action(rec, idx) {
+ const res: RecComponent = {
+ idx,
+ rec: rec as object,
+ component: action,
+ props: {
+ size: 'sm',
+ },
+ }
+ return res
+ },
+ }
}
diff --git a/app/components/app/device-order-item/list-entry.vue b/app/components/app/device-order-item/list-entry.vue
index 26f6691d..b6031228 100644
--- a/app/components/app/device-order-item/list-entry.vue
+++ b/app/components/app/device-order-item/list-entry.vue
@@ -1,13 +1,23 @@
-
+
-
diff --git a/app/components/app/device-order/confirmation-info.vue b/app/components/app/device-order/confirmation-info.vue
new file mode 100644
index 00000000..6711091f
--- /dev/null
+++ b/app/components/app/device-order/confirmation-info.vue
@@ -0,0 +1,26 @@
+
+
+
+
+ Tgl. Order
+
+
+ {{ data?.createdAt?.substring(0, 10) }}
+
+
+
+ DPJP
+
+
+ {{ data?.doctor?.employee?.person?.name }}
+
+
+
+
\ No newline at end of file
diff --git a/app/components/app/device-order/entry-form.vue b/app/components/app/device-order/entry-form.vue
index bea2b6eb..4e66c441 100644
--- a/app/components/app/device-order/entry-form.vue
+++ b/app/components/app/device-order/entry-form.vue
@@ -1,6 +1,25 @@
- Test
+
+
+ Tanggal
+
+ {{ data?.createdAt?.substring(0, 10) }}
+
+
+
+ DPJP
+
+ {{ data?.doctor?.employee?.person?.name }}
+
+
+
diff --git a/app/components/app/device-order/list.config.ts b/app/components/app/device-order/list.config.ts
index 7580c576..04a6c9fc 100644
--- a/app/components/app/device-order/list.config.ts
+++ b/app/components/app/device-order/list.config.ts
@@ -1,13 +1,18 @@
-import type { Config } from '~/components/pub/my-ui/data-table'
+import type { Config, RecComponent } from '~/components/pub/my-ui/data-table'
import type { DeviceOrder } from '~/models/device-order'
-import { defineAsyncComponent } from 'vue'
+import type { DeviceOrderItem } from '~/models/device-order-item'
-const action = defineAsyncComponent(() => import('~/components/pub/my-ui/data/dropdown-action-ud.vue'))
+const action = defineAsyncComponent(() => import('~/components/pub/my-ui/data/dropdown-action-dsd.vue'))
export const config: Config = {
- cols: [{ width: 120 }, { }, { }, { width: 50 }],
- headers: [[{ label: 'Tanggal' }, { label: 'DPJP' }, { label: 'Alat Kesehatan' }, { label: '' }]],
- keys: ['createdAt', 'encounter.doctor.person.name', 'items', 'action'],
+ cols: [{ width: 120 }, { }, { }, { }, { width: 50 }],
+ headers: [[
+ { label: 'Tanggal' },
+ { label: 'DPJP' },
+ { label: 'Alat Kesehatan' },
+ { label: 'Status' },
+ { label: '' }]],
+ keys: ['createdAt', 'doctor.employee.person.name', 'items', 'status_code', 'action'],
delKeyNames: [
{ key: 'code', label: 'Kode' },
{ key: 'name', label: 'Nama' },
@@ -16,27 +21,45 @@ export const config: Config = {
htmls: {
items: (rec: unknown): unknown => {
const recX = rec as DeviceOrder
- return recX.items?.length || 0
+ if (recX.items?.length > 0) {
+ let output = '
'
+ recX.items.forEach((item: DeviceOrderItem) => {
+ output += '' +
+ ''+
+ `| ${item.device?.name} | ` +
+ ': | ' +
+ `${item.quantity} | ` +
+ '
'
+ })
+ output += '
'
+ return output
+ } else {
+ return '-'
+ }
+ },
+ },
+ parses: {
+ createdAt: (rec: unknown): unknown => {
+ const recX = rec as DeviceOrder
+ return recX.createdAt ? new Date(recX.createdAt).toLocaleDateString() : '-'
+ },
+ // parent: (rec: unknown): unknown => {
+ // const recX = rec as SmallDetailDto
+ // return recX.parent?.name || '-'
+ // },
+ },
+ components: {
+ action(rec, idx) {
+ const res: RecComponent = {
+ idx,
+ rec: rec as object,
+ component: action,
+ props: {
+ size: 'sm',
+ },
+ }
+ return res
},
}
- // funcParsed: {
- // parent: (rec: unknown): unknown => {
- // const recX = rec as SmallDetailDto
- // return recX.parent?.name || '-'
- // },
- // },
- // funcComponent: {
- // action(rec: object, idx: any) {
- // const res: RecComponent = {
- // idx,
- // rec: rec as object,
- // component: action,
- // props: {
- // size: 'sm',
- // },
- // }
- // return res
- // },
- // }
}
diff --git a/app/components/app/device-order/list.vue b/app/components/app/device-order/list.vue
index 37b24ea3..83f57dd6 100644
--- a/app/components/app/device-order/list.vue
+++ b/app/components/app/device-order/list.vue
@@ -8,12 +8,10 @@ import type { PaginationMeta } from '~/components/pub/my-ui/pagination/paginatio
// Configs
import { config } from './list.config'
-interface Props {
+defineProps<{
data: any[]
paginationMeta: PaginationMeta
-}
-
-defineProps()
+}>()
const emit = defineEmits<{
pageChange: [page: number]
@@ -28,7 +26,7 @@ function handlePageChange(page: number) {
diff --git a/app/components/app/document-upload/_common/select-doc-type.vue b/app/components/app/document-upload/_common/select-doc-type.vue
new file mode 100644
index 00000000..70f78a7b
--- /dev/null
+++ b/app/components/app/document-upload/_common/select-doc-type.vue
@@ -0,0 +1,71 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/document-upload/entry-form.vue b/app/components/app/document-upload/entry-form.vue
new file mode 100644
index 00000000..f97a5161
--- /dev/null
+++ b/app/components/app/document-upload/entry-form.vue
@@ -0,0 +1,73 @@
+
+
+
+
+
diff --git a/app/components/app/document-upload/list.cfg.ts b/app/components/app/document-upload/list.cfg.ts
new file mode 100644
index 00000000..979c916d
--- /dev/null
+++ b/app/components/app/document-upload/list.cfg.ts
@@ -0,0 +1,43 @@
+import type { Config } from '~/components/pub/my-ui/data-table'
+import { defineAsyncComponent } from 'vue'
+import { docTypeCode, docTypeLabel, type docTypeCodeKey } from '~/lib/constants'
+
+const action = defineAsyncComponent(() => import('~/components/pub/my-ui/data/dropdown-action-dd.vue'))
+
+export const config: Config = {
+ cols: [{}, {}, {}, {width: 50},],
+
+ headers: [
+ [
+ { label: 'Nama Dokumen' },
+ { label: 'Tipe Dokumen' },
+ { label: 'Petugas Upload' },
+ { label: 'Action' },
+ ],
+ ],
+
+ keys: ['fileName', 'type_code', 'employee.name', 'action'],
+
+ delKeyNames: [
+
+ ],
+
+ parses: {
+ type_code: (v: unknown) => {
+ return docTypeLabel[v?.type_code as docTypeCodeKey]
+ },
+ },
+
+ components: {
+ action(rec, idx) {
+ return {
+ idx,
+ rec: rec as object,
+ component: action,
+ }
+ },
+ },
+
+ htmls: {
+ },
+}
diff --git a/app/components/app/document-upload/list.vue b/app/components/app/document-upload/list.vue
new file mode 100644
index 00000000..8274e752
--- /dev/null
+++ b/app/components/app/document-upload/list.vue
@@ -0,0 +1,31 @@
+
+
+
+
+
diff --git a/app/components/app/general-consent/entry.vue b/app/components/app/general-consent/entry.vue
new file mode 100644
index 00000000..75e30cec
--- /dev/null
+++ b/app/components/app/general-consent/entry.vue
@@ -0,0 +1,214 @@
+
+
+
+
+
diff --git a/app/components/app/general-consent/list.cfg.ts b/app/components/app/general-consent/list.cfg.ts
new file mode 100644
index 00000000..c2f57c54
--- /dev/null
+++ b/app/components/app/general-consent/list.cfg.ts
@@ -0,0 +1,82 @@
+import type { Config, RecComponent, RecStrFuncComponent, RecStrFuncUnknown } from '~/components/pub/my-ui/data-table'
+import { defineAsyncComponent } from 'vue'
+import type { GeneralConsent } from '~/models/general-consent'
+
+type SmallDetailDto = any
+
+const action = defineAsyncComponent(() => import('~/components/pub/my-ui/data/dropdown-action-ud.vue'))
+export const config: Config = {
+ cols: [{ width: 100 }, {}, {}, {}, { width: 50 }],
+ headers: [
+ [
+ { label: 'Tanggal' },
+ { label: 'Anggota Keluarga' },
+ { label: 'Penanggung Jawab' },
+ { label: 'Pemberi Informasi' },
+ { label: 'Saksi 1' },
+ { label: 'Saksi 2' },
+ { label: '' },
+ ],
+ ],
+ keys: ['date', 'relatives', 'responsible', 'informant', 'witness1', 'witness2', 'action'],
+ delKeyNames: [
+ { key: 'data', label: 'Tanggal' },
+ { key: 'dstDoctor.name', label: 'Dokter' },
+ ],
+ parses: {
+ date(rec) {
+ const recX = rec as GeneralConsent
+ return recX?.createdAt?.substring(0, 10) || '-'
+ },
+ relatives(rec) {
+ const recX = rec as GeneralConsent
+ const parsed = JSON.parse(recX?.value || '{}')
+ return parsed?.relatives?.join(', ') || '-'
+ },
+ responsible(rec) {
+ const recX = rec as GeneralConsent
+ const parsed = JSON.parse(recX?.value || '{}')
+ return parsed?.responsible || '-'
+ },
+ informant(rec) {
+ const recX = rec as GeneralConsent
+ const parsed = JSON.parse(recX?.value || '{}')
+ return parsed?.informant || '-'
+ },
+ witness1(rec) {
+ const recX = rec as GeneralConsent
+ const parsed = JSON.parse(recX?.value || '{}')
+ return parsed?.witness1 || '-'
+ },
+ witness2(rec) {
+ const recX = rec as GeneralConsent
+ const parsed = JSON.parse(recX?.value || '{}')
+ return parsed?.witness2 || '-'
+ },
+ action(rec, idx) {
+ const res: RecComponent = {
+ idx,
+ rec: rec as object,
+ component: action,
+ props: {
+ size: 'sm',
+ },
+ }
+ return res
+ },
+ },
+ components: {
+ action(rec, idx) {
+ const res: RecComponent = {
+ idx,
+ rec: rec as object,
+ component: action,
+ props: {
+ size: 'sm',
+ },
+ }
+ return res
+ },
+ } as RecStrFuncComponent,
+ htmls: {} as RecStrFuncUnknown,
+}
diff --git a/app/components/app/general-consent/list.vue b/app/components/app/general-consent/list.vue
new file mode 100644
index 00000000..46f595f5
--- /dev/null
+++ b/app/components/app/general-consent/list.vue
@@ -0,0 +1,34 @@
+
+
+
+
+
diff --git a/app/components/app/medicine-form/entry-form.vue b/app/components/app/medicine-form/entry-form.vue
new file mode 100644
index 00000000..fb26631e
--- /dev/null
+++ b/app/components/app/medicine-form/entry-form.vue
@@ -0,0 +1,119 @@
+
+
+
+
+
diff --git a/app/components/app/medicine-form/list-cfg.ts b/app/components/app/medicine-form/list-cfg.ts
new file mode 100644
index 00000000..5b66812a
--- /dev/null
+++ b/app/components/app/medicine-form/list-cfg.ts
@@ -0,0 +1,38 @@
+import type { Config, RecComponent } from '~/components/pub/my-ui/data-table'
+import { defineAsyncComponent } from 'vue'
+
+const action = defineAsyncComponent(() => import('~/components/pub/my-ui/data/dropdown-action-ud.vue'))
+
+export const config: Config = {
+ cols: [{}, {}, { width: 50 }],
+
+ headers: [
+ [
+ { label: 'Kode' },
+ { label: 'Nama' },
+ { label: 'Aksi' },
+ ],
+ ],
+
+ keys: ['code', 'name', 'action'],
+
+ delKeyNames: [
+ { key: 'code', label: 'Kode' },
+ { key: 'name', label: 'Nama' },
+ ],
+
+ parses: {},
+
+ components: {
+ action(rec, idx) {
+ const res: RecComponent = {
+ idx,
+ rec: rec as object,
+ component: action,
+ }
+ return res
+ },
+ },
+
+ htmls: {},
+}
diff --git a/app/components/app/medicine-form/list.vue b/app/components/app/medicine-form/list.vue
new file mode 100644
index 00000000..e4544c2f
--- /dev/null
+++ b/app/components/app/medicine-form/list.vue
@@ -0,0 +1,35 @@
+
+
+
+
+
diff --git a/app/components/app/medicine/entry-form.vue b/app/components/app/medicine/entry-form.vue
index 42989fcb..af4df34f 100644
--- a/app/components/app/medicine/entry-form.vue
+++ b/app/components/app/medicine/entry-form.vue
@@ -18,6 +18,7 @@ interface Props {
isReadonly?: boolean
medicineGroups?: { value: string; label: string }[]
medicineMethods?: { value: string; label: string }[]
+ medicineForms?: { value: string; label: string }[]
uoms?: { value: string; label: string }[]
}
@@ -36,6 +37,7 @@ const { defineField, errors, meta } = useForm({
name: '',
medicineGroup_code: '',
medicineMethod_code: '',
+ medicineForm_code: '',
uom_code: '',
stock: 0,
},
@@ -45,6 +47,7 @@ const [code, codeAttrs] = defineField('code')
const [name, nameAttrs] = defineField('name')
const [medicineGroup_code, medicineGroupAttrs] = defineField('medicineGroup_code')
const [medicineMethod_code, medicineMethodAttrs] = defineField('medicineMethod_code')
+const [medicineForm_code, medicineFormAttrs] = defineField('medicineForm_code')
const [uom_code, uomAttrs] = defineField('uom_code')
const [stock, stockAttrs] = defineField('stock')
@@ -53,6 +56,7 @@ if (props.values) {
if (props.values.name !== undefined) name.value = props.values.name
if (props.values.medicineGroup_code !== undefined) medicineGroup_code.value = props.values.medicineGroup_code
if (props.values.medicineMethod_code !== undefined) medicineMethod_code.value = props.values.medicineMethod_code
+ if (props.values.medicineForm_code !== undefined) medicineForm_code.value = props.values.medicineForm_code
if (props.values.uom_code !== undefined) uom_code.value = props.values.uom_code
if (props.values.stock !== undefined) stock.value = props.values.stock
}
@@ -62,6 +66,7 @@ const resetForm = () => {
name.value = ''
medicineGroup_code.value = ''
medicineMethod_code.value = ''
+ medicineForm_code.value = '',
uom_code.value = ''
stock.value = 0
}
@@ -72,6 +77,7 @@ function onSubmitForm() {
name: name.value || '',
medicineGroup_code: medicineGroup_code.value || '',
medicineMethod_code: medicineMethod_code.value || '',
+ medicineForm_code: medicineForm_code.value || '',
uom_code: uom_code.value || '',
stock: stock.value || 0,
}
@@ -138,6 +144,20 @@ function onCancelForm() {
/>
+
+
+
+
+
+ |
diff --git a/app/components/app/medicine/list-cfg.ts b/app/components/app/medicine/list-cfg.ts
index 059022c8..5d1740f8 100644
--- a/app/components/app/medicine/list-cfg.ts
+++ b/app/components/app/medicine/list-cfg.ts
@@ -15,12 +15,13 @@ export const config: Config = {
{ label: 'Golongan' },
{ label: 'Metode Pemberian' },
{ label: 'Satuan' },
+ { label: 'Sediaan' },
{ label: 'Stok' },
{ label: 'Aksi' },
],
],
- keys: ['code', 'name', 'group', 'method', 'unit', 'stock', 'action'],
+ keys: ['code', 'name', 'group', 'method', 'unit', 'form', 'stock', 'action'],
delKeyNames: [
{ key: 'code', label: 'Kode' },
@@ -37,6 +38,9 @@ export const config: Config = {
unit: (rec: unknown): unknown => {
return (rec as SmallDetailDto).uom?.name || '-'
},
+ form: (rec: unknown): unknown => {
+ return (rec as SmallDetailDto).medicineForm?.name || '-'
+ },
},
components: {
diff --git a/app/components/app/prescription-item/list-entry.cfg.ts b/app/components/app/prescription-item/list-entry.cfg.ts
index 070dd65f..cfc6bdbd 100644
--- a/app/components/app/prescription-item/list-entry.cfg.ts
+++ b/app/components/app/prescription-item/list-entry.cfg.ts
@@ -11,16 +11,17 @@ export const config: Config = {
headers: [
[
{ label: 'Nama' },
+ { label: 'Cara Buat' },
{ label: 'Bentuk' },
{ label: 'Freq' },
{ label: 'Dosis' },
- { label: 'Interval' },
+ // { label: 'Interval' },
{ label: 'Total' },
{ label: '' },
],
],
- keys: ['name', 'uom_code', 'frequency', 'multiplier', 'interval', 'total', 'action'],
+ keys: ['medicine.name', 'isMix', 'medicine.medicineForm.name', 'frequency', 'dose', 'quantity', 'action'], //
delKeyNames: [
{ key: 'code', label: 'Kode' },
@@ -28,17 +29,8 @@ export const config: Config = {
],
parses: {
- cateogry: (rec: unknown): unknown => {
- return (rec as SmallDetailDto).medicineCategory?.name || '-'
- },
- group: (rec: unknown): unknown => {
- return (rec as SmallDetailDto).medicineGroup?.name || '-'
- },
- method: (rec: unknown): unknown => {
- return (rec as SmallDetailDto).medicineMethod?.name || '-'
- },
- unit: (rec: unknown): unknown => {
- return (rec as SmallDetailDto).medicineUnit?.name || '-'
+ isMix: (rec: unknown): unknown => {
+ return (rec as SmallDetailDto).isMix ? 'Racikan' : 'Non Racikan'
},
},
diff --git a/app/components/app/prescription-item/list.cfg.ts b/app/components/app/prescription-item/list.cfg.ts
index fd980bb1..5a3447ef 100644
--- a/app/components/app/prescription-item/list.cfg.ts
+++ b/app/components/app/prescription-item/list.cfg.ts
@@ -12,12 +12,11 @@ export const config: Config = {
{ label: 'Bentuk' },
{ label: 'Freq' },
{ label: 'Dosis' },
- { label: 'Interval' },
{ label: 'Total' },
],
],
- keys: ['name', 'uom_code', 'frequency', 'multiplier', 'interval', 'total'],
+ keys: ['medicine.name', 'medicine.medicineForm.name', 'frequency', 'dose', 'total'],
delKeyNames: [
{ key: 'code', label: 'Kode' },
diff --git a/app/components/app/prescription-item/list.vue b/app/components/app/prescription-item/list.vue
index ed64b09e..d8c4c107 100644
--- a/app/components/app/prescription-item/list.vue
+++ b/app/components/app/prescription-item/list.vue
@@ -1,4 +1,6 @@
-
diff --git a/app/components/app/prescription-item/mix-entry.vue b/app/components/app/prescription-item/mix-entry.vue
index d9b4881e..05960307 100644
--- a/app/components/app/prescription-item/mix-entry.vue
+++ b/app/components/app/prescription-item/mix-entry.vue
@@ -1,29 +1,36 @@
-
-
- Nama
-
+
+
+ Nama
+
+
+
- Frequensi
-
+ Frequensi
+
- Dosis
-
+ Dosis
+
- Sediaan
-
+ Sediaan
+
- Total
-
+ Total
+
-
- Cara Pakai
-
+
+ Cara Pakai
+
Daftar Obat
@@ -77,20 +94,29 @@ function addItem() {
Nama
Dosis
- Satuan
- ..
+
+
-
+
-
+
-
+
+
+
+
+
@@ -102,7 +128,7 @@ function addItem() {
-
+
Tambah
diff --git a/app/components/app/prescription-item/non-mix-entry.vue b/app/components/app/prescription-item/non-mix-entry.vue
index 25970646..78ee9ada 100644
--- a/app/components/app/prescription-item/non-mix-entry.vue
+++ b/app/components/app/prescription-item/non-mix-entry.vue
@@ -2,40 +2,45 @@
import * as DE from '~/components/pub/my-ui/doc-entry'
import Separator from '~/components/pub/ui/separator/Separator.vue'
import Nav from '~/components/pub/my-ui/nav-footer/cl-sa.vue'
+import * as CB from '~/components/pub/my-ui/combobox'
-import { bigTimeUnitCodes } from '~/lib/constants'
+// import { bigTimeUnitCodes } from '~/lib/constants'
+import { type Medicine } from '~/models/medicine';
import type { PrescriptionItem } from '~/models/prescription-item'
const props = defineProps<{
data: PrescriptionItem
+ medicines: Medicine[]
}>()
+const { medicines } = toRefs(props)
+const medicineItems = ref([])
+const medicineForm = computed(() => {
+ const medicine = props.medicines.find(m => m.code === props.data.medicine_code)
+ return medicine ? medicine.medicineForm?.name : '--tidak diketahui--'
+})
+
type ClickType = 'close' | 'save'
type Item = {
value: string
label: string
}
-const bigTimeUnitCodeItems: Item[] = []
-
if(!props.data.intervalUnit_code) {
props.data.intervalUnit_code = 'day'
}
-Object.keys(bigTimeUnitCodes).forEach((key) => {
- bigTimeUnitCodeItems.push({
- value: key,
- label: bigTimeUnitCodes[key] || '',
- })
-})
-
-
const emit = defineEmits<{
close: [],
save: [data: PrescriptionItem],
+ 'update:searchText': [value: string]
}>()
+watch(medicines, (data) => {
+ medicineItems.value = CB.objectsToItems(data, 'code', 'name')
+})
+
function navClick(type: ClickType) {
if (type === 'close') {
emit('close')
@@ -43,13 +48,23 @@ function navClick(type: ClickType) {
emit('save', props.data)
}
}
+
+function searchMedicineText(value: string) {
+ emit('update:searchText', value)
+}
-
-
- Nama
-
+
+
+ Nama
+
+
+
Frequensi
@@ -59,11 +74,7 @@ function navClick(type: ClickType) {
Dosis
-
- Sediaan
-
-
-
+
Total
-
+
-
+
+ Sediaan
+
+
+
Cara Pakai
-
+
diff --git a/app/components/app/prescription/detail.vue b/app/components/app/prescription/detail.vue
index 694eb9a1..21962532 100644
--- a/app/components/app/prescription/detail.vue
+++ b/app/components/app/prescription/detail.vue
@@ -13,7 +13,7 @@ const props = defineProps<{
Order {{ data.issuedAt?.substring(0, 10) || data.createdAt?.substring(0, 10) }} - {{ data.status_code }}
-
+
DPJP
diff --git a/app/components/app/prescription/entry.vue b/app/components/app/prescription/entry.vue
index ef8756e8..28041eea 100644
--- a/app/components/app/prescription/entry.vue
+++ b/app/components/app/prescription/entry.vue
@@ -1,17 +1,25 @@
+
+
-
+
+
diff --git a/app/components/app/prescription/flat-list.vue b/app/components/app/prescription/flat-list.vue
new file mode 100644
index 00000000..fe0bab9c
--- /dev/null
+++ b/app/components/app/prescription/flat-list.vue
@@ -0,0 +1,86 @@
+
+
+
+
+ Belum Ada Data
+
+
+
+ Tambah Order
+
+
+
+
+
+
+ Tgl Order
+ DPJP
+ PPDS
+ Jenis Obat
+ Status
+
+
+
+
+
+
+ {{ item.issuedAt?.substring(0, 10) || item.createdAt?.substring(0, 10) }}
+
+
+ {{ item.doctor?.employee?.person?.name || '-' }}
+
+
+
+
+
+ Racikan: {{ item.items.filter(function(element){ return element.isMix}).length }}
+
+
+ Non Racikan: {{ item.items.filter(function(element){ return !element.isMix}).length }}
+
+
+
+ {{ item.status_code }}
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/prescription/list.vue b/app/components/app/prescription/grouped-list.vue
similarity index 95%
rename from app/components/app/prescription/list.vue
rename to app/components/app/prescription/grouped-list.vue
index ae5126ca..07d6fcaa 100644
--- a/app/components/app/prescription/list.vue
+++ b/app/components/app/prescription/grouped-list.vue
@@ -5,7 +5,6 @@ import Nav from '~/components/pub/my-ui/nav-footer/ca-ed-su.vue'
import type { Prescription } from '~/models/prescription';
import PrescriptionItem from '~/components/app/prescription-item/list.vue';
-import { add } from 'date-fns';
interface Props {
data: Prescription[]
@@ -66,7 +65,7 @@ function navClick(type: 'cancel' | 'edit' | 'submit', data: Prescription): void
/>
-
+
diff --git a/app/components/app/prescription/list-with-sub.vue b/app/components/app/prescription/list-with-sub.vue
index 14bc1785..4d1a2cdf 100644
--- a/app/components/app/prescription/list-with-sub.vue
+++ b/app/components/app/prescription/list-with-sub.vue
@@ -1,7 +1,5 @@
@@ -17,40 +15,40 @@
-
-
- Order #1
-
-
+
+
+ Order #1
+
+
2025-01-01
-
-
-
- Status
-
-
+
+
+
+ Status
+
+
Status
-
-
-
+
+
+
-
-
- DPJP
-
-
+
+
+ DPJP
+
+
Nama Dokter
-
-
-
- PPDS
-
-
+
+
+
+ PPDS
+
+
Nama PPDS
-
-
-
+
+
+
diff --git a/app/components/app/resume/_common/print-btn.vue b/app/components/app/resume/_common/print-btn.vue
new file mode 100644
index 00000000..5688d007
--- /dev/null
+++ b/app/components/app/resume/_common/print-btn.vue
@@ -0,0 +1,22 @@
+
+
+
+
+
+ {{ props.btnTxt || 'Lampiran' }}
+
+
\ No newline at end of file
diff --git a/app/components/app/resume/_common/select-arrangement.vue b/app/components/app/resume/_common/select-arrangement.vue
new file mode 100644
index 00000000..7e236ff0
--- /dev/null
+++ b/app/components/app/resume/_common/select-arrangement.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-concious-level.vue b/app/components/app/resume/_common/select-concious-level.vue
new file mode 100644
index 00000000..0852195b
--- /dev/null
+++ b/app/components/app/resume/_common/select-concious-level.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-date.vue b/app/components/app/resume/_common/select-date.vue
new file mode 100644
index 00000000..74245e7e
--- /dev/null
+++ b/app/components/app/resume/_common/select-date.vue
@@ -0,0 +1,121 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+ {
+ const dateStr = typeof value === 'number' ? String(value) : value
+ patientAge = calculateAge(dateStr)
+ }
+ "
+ />
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-death-cause.vue b/app/components/app/resume/_common/select-death-cause.vue
new file mode 100644
index 00000000..a155b139
--- /dev/null
+++ b/app/components/app/resume/_common/select-death-cause.vue
@@ -0,0 +1,71 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-faskes.vue b/app/components/app/resume/_common/select-faskes.vue
new file mode 100644
index 00000000..0852195b
--- /dev/null
+++ b/app/components/app/resume/_common/select-faskes.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-following-arrangement.vue b/app/components/app/resume/_common/select-following-arrangement.vue
new file mode 100644
index 00000000..0852195b
--- /dev/null
+++ b/app/components/app/resume/_common/select-following-arrangement.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-hospital-leave-condition.vue b/app/components/app/resume/_common/select-hospital-leave-condition.vue
new file mode 100644
index 00000000..0852195b
--- /dev/null
+++ b/app/components/app/resume/_common/select-hospital-leave-condition.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-hospital-leave-method.vue b/app/components/app/resume/_common/select-hospital-leave-method.vue
new file mode 100644
index 00000000..0852195b
--- /dev/null
+++ b/app/components/app/resume/_common/select-hospital-leave-method.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-icd-10.vue b/app/components/app/resume/_common/select-icd-10.vue
new file mode 100644
index 00000000..0852195b
--- /dev/null
+++ b/app/components/app/resume/_common/select-icd-10.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-icd-9.vue b/app/components/app/resume/_common/select-icd-9.vue
new file mode 100644
index 00000000..0852195b
--- /dev/null
+++ b/app/components/app/resume/_common/select-icd-9.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-national-program-service-status.vue b/app/components/app/resume/_common/select-national-program-service-status.vue
new file mode 100644
index 00000000..0852195b
--- /dev/null
+++ b/app/components/app/resume/_common/select-national-program-service-status.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-national-program-service.vue b/app/components/app/resume/_common/select-national-program-service.vue
new file mode 100644
index 00000000..0852195b
--- /dev/null
+++ b/app/components/app/resume/_common/select-national-program-service.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-pain-scale.vue b/app/components/app/resume/_common/select-pain-scale.vue
new file mode 100644
index 00000000..0852195b
--- /dev/null
+++ b/app/components/app/resume/_common/select-pain-scale.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-primary-diagnosis.vue b/app/components/app/resume/_common/select-primary-diagnosis.vue
new file mode 100644
index 00000000..0852195b
--- /dev/null
+++ b/app/components/app/resume/_common/select-primary-diagnosis.vue
@@ -0,0 +1,70 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/select-secondary-diagnosis.vue b/app/components/app/resume/_common/select-secondary-diagnosis.vue
new file mode 100644
index 00000000..a155b139
--- /dev/null
+++ b/app/components/app/resume/_common/select-secondary-diagnosis.vue
@@ -0,0 +1,71 @@
+
+
+
+
+
+ {{ label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/resume/_common/verify-badge.vue b/app/components/app/resume/_common/verify-badge.vue
new file mode 100644
index 00000000..8a999895
--- /dev/null
+++ b/app/components/app/resume/_common/verify-badge.vue
@@ -0,0 +1,67 @@
+
+
+
+
+
+ {{ statusText }}
+
+
+
\ No newline at end of file
diff --git a/app/components/app/resume/add.vue b/app/components/app/resume/add.vue
new file mode 100644
index 00000000..d5fa3370
--- /dev/null
+++ b/app/components/app/resume/add.vue
@@ -0,0 +1,482 @@
+
+
+
+
+
diff --git a/app/components/app/resume/history-list/action-history-dialog.vue b/app/components/app/resume/history-list/action-history-dialog.vue
new file mode 100644
index 00000000..5602016e
--- /dev/null
+++ b/app/components/app/resume/history-list/action-history-dialog.vue
@@ -0,0 +1,66 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/app/components/app/resume/history-list/action-list.cfg.ts b/app/components/app/resume/history-list/action-list.cfg.ts
new file mode 100644
index 00000000..2dad3e6a
--- /dev/null
+++ b/app/components/app/resume/history-list/action-list.cfg.ts
@@ -0,0 +1,94 @@
+import type { Config } from '~/components/pub/my-ui/data-table'
+import type { Patient } from '~/models/patient'
+import { defineAsyncComponent } from 'vue'
+import { educationCodes, genderCodes } from '~/lib/constants'
+import { calculateAge } from '~/lib/utils'
+
+const action = defineAsyncComponent(() => import('~/components/pub/my-ui/data/dropdown-action-dvvp.vue'))
+
+export const config: Config = {
+ cols: [{width: 140}, {}, {}, {width: 140}, {width: 10},],
+
+ headers: [
+ [
+ { label: 'Tanggal/Jam' },
+ { label: 'Dokter' },
+ { label: 'Tempat Layanan' },
+ { label: 'Jenis' },
+ { label: 'Jenis Pemeriksaan' },
+ { label: 'Tanggal/Jam' },
+ ],
+ ],
+
+ keys: ['birth_date', 'person.name', 'person.name', 'person.name', 'person.name', 'birth_date',],
+
+ delKeyNames: [
+ { key: 'code', label: 'Kode' },
+ { key: 'name', label: 'Nama' },
+ ],
+
+ parses: {
+ patientId: (rec: unknown): unknown => {
+ const patient = rec as Patient
+ return patient.number
+ },
+ identity_number: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+
+ if (person.nationality == 'WNA') {
+ return person.passportNumber
+ }
+
+ return person.residentIdentityNumber || '-'
+ },
+ birth_date: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+
+ if (typeof person.birthDate == 'object' && person.birthDate) {
+ return (person.birthDate as Date).toLocaleDateString('id-ID')
+ } else if (typeof person.birthDate == 'string') {
+ return (person.birthDate as string).substring(0, 10)
+ }
+ return person.birthDate
+ },
+ patient_age: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+ return calculateAge(person.birthDate)
+ },
+ gender: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+
+ if (typeof person.gender_code == 'number' && person.gender_code >= 0) {
+ return person.gender_code
+ } else if (typeof person.gender_code === 'string' && person.gender_code) {
+ return genderCodes[person.gender_code] || '-'
+ }
+ return '-'
+ },
+ education: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+ if (typeof person.education_code == 'number' && person.education_code >= 0) {
+ return person.education_code
+ } else if (typeof person.education_code === 'string' && person.education_code) {
+ return educationCodes[person.education_code] || '-'
+ }
+ return '-'
+ },
+ },
+
+ components: {
+ action(rec, idx) {
+ return {
+ idx,
+ rec: rec as object,
+ component: action,
+ }
+ },
+ },
+
+ htmls: {
+ patient_address(_rec) {
+ return '-'
+ },
+ },
+}
diff --git a/app/components/app/resume/history-list/consultation-history-dialog.vue b/app/components/app/resume/history-list/consultation-history-dialog.vue
new file mode 100644
index 00000000..ad1e777e
--- /dev/null
+++ b/app/components/app/resume/history-list/consultation-history-dialog.vue
@@ -0,0 +1,66 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/app/components/app/resume/history-list/consultation-list.cfg.ts b/app/components/app/resume/history-list/consultation-list.cfg.ts
new file mode 100644
index 00000000..196c208c
--- /dev/null
+++ b/app/components/app/resume/history-list/consultation-list.cfg.ts
@@ -0,0 +1,51 @@
+import type { Config } from '~/components/pub/my-ui/data-table'
+import type { Patient } from '~/models/patient'
+import { defineAsyncComponent } from 'vue'
+
+const lampiranBtn = defineAsyncComponent(() => import('../_common/print-btn.vue'))
+
+export const config: Config = {
+ cols: [{}, {}, {}, {}, {},],
+
+ headers: [
+ [
+ { label: 'Tanggal/Jam' },
+ { label: 'Dokter' },
+ { label: 'Tempat Layanan' },
+ { label: 'KSM' },
+ { label: 'Tanggal/Jam' },
+ { label: 'Tujuan' },
+ { label: 'Dokter' },
+ { label: 'Berkas' },
+ ],
+ ],
+
+ keys: ['birth_date', 'person.name', 'person.name', 'person.name', 'person.name', 'birth_date','person.name', 'action', ],
+
+ parses: {
+ birth_date: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+
+ if (typeof person.birthDate == 'object' && person.birthDate) {
+ return (person.birthDate as Date).toLocaleDateString('id-ID')
+ } else if (typeof person.birthDate == 'string') {
+ return (person.birthDate as string).substring(0, 10)
+ }
+ return person.birthDate
+ },
+ },
+
+ components: {
+ action(rec, idx) {
+ return {
+ idx,
+ rec: rec as object,
+ component: lampiranBtn,
+ }
+ },
+ },
+
+ htmls: {
+
+ },
+}
diff --git a/app/components/app/resume/history-list/farmacy-history-dialog.vue b/app/components/app/resume/history-list/farmacy-history-dialog.vue
new file mode 100644
index 00000000..53bf3875
--- /dev/null
+++ b/app/components/app/resume/history-list/farmacy-history-dialog.vue
@@ -0,0 +1,66 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/app/components/app/resume/history-list/farmacy-list.cfg.ts b/app/components/app/resume/history-list/farmacy-list.cfg.ts
new file mode 100644
index 00000000..75ea1e80
--- /dev/null
+++ b/app/components/app/resume/history-list/farmacy-list.cfg.ts
@@ -0,0 +1,39 @@
+import type { Config } from '~/components/pub/my-ui/data-table'
+import type { Patient } from '~/models/patient'
+
+export const config: Config = {
+ cols: [{}, {}, {}, {}, {},],
+
+ headers: [
+ [
+ { label: 'Tanggal Order' },
+ { label: 'No Resep' },
+ { label: 'Tempat Layanan' },
+ { label: 'Nama Obat' },
+ { label: 'Tanggal Disetujui' },
+ ],
+ ],
+
+ keys: ['birth_date', 'person.name', 'person.name', 'person.name', 'birth_date',],
+
+ parses: {
+ birth_date: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+
+ if (typeof person.birthDate == 'object' && person.birthDate) {
+ return (person.birthDate as Date).toLocaleDateString('id-ID')
+ } else if (typeof person.birthDate == 'string') {
+ return (person.birthDate as string).substring(0, 10)
+ }
+ return person.birthDate
+ },
+ },
+
+ components: {
+
+ },
+
+ htmls: {
+
+ },
+}
diff --git a/app/components/app/resume/history-list/national-program-history-dialog.vue b/app/components/app/resume/history-list/national-program-history-dialog.vue
new file mode 100644
index 00000000..cc702227
--- /dev/null
+++ b/app/components/app/resume/history-list/national-program-history-dialog.vue
@@ -0,0 +1,65 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/app/components/app/resume/history-list/national-program-list.cfg.ts b/app/components/app/resume/history-list/national-program-list.cfg.ts
new file mode 100644
index 00000000..fe6d3ea0
--- /dev/null
+++ b/app/components/app/resume/history-list/national-program-list.cfg.ts
@@ -0,0 +1,30 @@
+import type { Config } from '~/components/pub/my-ui/data-table'
+import type { Patient } from '~/models/patient'
+
+export const config: Config = {
+ cols: [{}, {}, {}, {}, {},],
+
+ headers: [
+ [
+ { label: 'Nomor' },
+ { label: 'Layanan Program Nasional' },
+ { label: 'Status' },
+ ],
+ ],
+
+ keys: ['person.name', 'person.name', 'person.name',],
+
+ parses: {
+ // birth_date: (rec: unknown): unknown => {
+
+ // },
+ },
+
+ components: {
+
+ },
+
+ htmls: {
+
+ },
+}
diff --git a/app/components/app/resume/history-list/supporting-history-dialog.vue b/app/components/app/resume/history-list/supporting-history-dialog.vue
new file mode 100644
index 00000000..32fb4508
--- /dev/null
+++ b/app/components/app/resume/history-list/supporting-history-dialog.vue
@@ -0,0 +1,66 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/app/components/app/resume/history-list/supporting-list.cfg.ts b/app/components/app/resume/history-list/supporting-list.cfg.ts
new file mode 100644
index 00000000..f005042d
--- /dev/null
+++ b/app/components/app/resume/history-list/supporting-list.cfg.ts
@@ -0,0 +1,39 @@
+import type { Config } from '~/components/pub/my-ui/data-table'
+import type { Patient } from '~/models/patient'
+
+export const config: Config = {
+ cols: [{}, {}, {}, {}, {},],
+
+ headers: [
+ [
+ { label: 'Tanggal Order' },
+ { label: 'No Lab' },
+ { label: 'Nama Pemeriksaan' },
+ { label: 'Tanggal Pemeriksaan' },
+ ],
+ ],
+
+ keys: ['birth_date', 'person.name', 'person.name', 'birth_date',],
+
+ parses: {
+ birth_date: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+
+ if (typeof person.birthDate == 'object' && person.birthDate) {
+ return (person.birthDate as Date).toLocaleDateString('id-ID')
+ } else if (typeof person.birthDate == 'string') {
+ return (person.birthDate as string).substring(0, 10)
+ }
+ return person.birthDate
+ },
+ },
+
+ components: {
+ },
+
+ htmls: {
+ // patient_address(_rec) {
+ // return '-'
+ // },
+ },
+}
diff --git a/app/components/app/resume/list.cfg.ts b/app/components/app/resume/list.cfg.ts
new file mode 100644
index 00000000..b756b1ee
--- /dev/null
+++ b/app/components/app/resume/list.cfg.ts
@@ -0,0 +1,101 @@
+import type { Config } from '~/components/pub/my-ui/data-table'
+import type { Patient } from '~/models/patient'
+import { defineAsyncComponent } from 'vue'
+import { educationCodes, genderCodes } from '~/lib/constants'
+import { calculateAge } from '~/lib/utils'
+
+const action = defineAsyncComponent(() => import('~/components/pub/my-ui/data/dropdown-action-dvvp.vue'))
+const statusBadge = defineAsyncComponent(() => import('./_common/verify-badge.vue'))
+
+export const config: Config = {
+ cols: [{width: 140}, {}, {}, {width: 140}, {width: 10},],
+
+ headers: [
+ [
+ { label: 'Tgl Simpan' },
+ { label: 'DPJP' },
+ { label: 'KSM' },
+ { label: 'Status' },
+ { label: 'Action' },
+ ],
+ ],
+
+ keys: ['birth_date', 'number', 'person.name', 'status', 'action'],
+
+ delKeyNames: [
+ { key: 'code', label: 'Kode' },
+ { key: 'name', label: 'Nama' },
+ ],
+
+ parses: {
+ patientId: (rec: unknown): unknown => {
+ const patient = rec as Patient
+ return patient.number
+ },
+ identity_number: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+
+ if (person.nationality == 'WNA') {
+ return person.passportNumber
+ }
+
+ return person.residentIdentityNumber || '-'
+ },
+ birth_date: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+
+ if (typeof person.birthDate == 'object' && person.birthDate) {
+ return (person.birthDate as Date).toLocaleDateString('id-ID')
+ } else if (typeof person.birthDate == 'string') {
+ return (person.birthDate as string).substring(0, 10)
+ }
+ return person.birthDate
+ },
+ patient_age: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+ return calculateAge(person.birthDate)
+ },
+ gender: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+
+ if (typeof person.gender_code == 'number' && person.gender_code >= 0) {
+ return person.gender_code
+ } else if (typeof person.gender_code === 'string' && person.gender_code) {
+ return genderCodes[person.gender_code] || '-'
+ }
+ return '-'
+ },
+ education: (rec: unknown): unknown => {
+ const { person } = rec as Patient
+ if (typeof person.education_code == 'number' && person.education_code >= 0) {
+ return person.education_code
+ } else if (typeof person.education_code === 'string' && person.education_code) {
+ return educationCodes[person.education_code] || '-'
+ }
+ return '-'
+ },
+ },
+
+ components: {
+ action(rec, idx) {
+ return {
+ idx,
+ rec: rec as object,
+ component: action,
+ }
+ },
+ status(rec, idx) {
+ return {
+ idx,
+ rec: rec as object,
+ component: statusBadge,
+ }
+ },
+ },
+
+ htmls: {
+ patient_address(_rec) {
+ return '-'
+ },
+ },
+}
diff --git a/app/components/app/resume/list.vue b/app/components/app/resume/list.vue
new file mode 100644
index 00000000..0d62cc6c
--- /dev/null
+++ b/app/components/app/resume/list.vue
@@ -0,0 +1,31 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/app/components/app/resume/verify-dialog.vue b/app/components/app/resume/verify-dialog.vue
new file mode 100644
index 00000000..ca4fb554
--- /dev/null
+++ b/app/components/app/resume/verify-dialog.vue
@@ -0,0 +1,98 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/app/components/content/device-order/entry.vue b/app/components/content/device-order/entry.vue
index 6d76d685..5d87d960 100644
--- a/app/components/content/device-order/entry.vue
+++ b/app/components/content/device-order/entry.vue
@@ -1,24 +1,177 @@
@@ -28,10 +181,74 @@ const headerPrep: HeaderPrep = {
class="mb-4 xl:mb-5"
/>
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ handleActionRemove(recId, getDeviceOrderItems, toast)"
+ @cancel=""
+ >
+
+
+ Nama
+
+
+ {{ recItem.device.name }}
+
+
+
+ Dosis
+
+
+ {{ recItem.quantity }}
+
+
+
+
diff --git a/app/components/content/device-order/list.vue b/app/components/content/device-order/list.vue
index e62a2fbd..1ffa324d 100644
--- a/app/components/content/device-order/list.vue
+++ b/app/components/content/device-order/list.vue
@@ -1,69 +1,39 @@
@@ -108,38 +145,39 @@ onMounted(async () => {
:prep="headerPrep"
:ref-search-nav="headerPrep.refSearchNav"
@search="handleSearch"
- class="mb-4 xl:mb-5"
/>
+
-
+
handleActionSubmit(recId, getMyList, toast)"
+ >
+
+
+
+
+ handleActionRemove(recId, getMyList, toast)"
- @cancel=""
>
-
-
-
- ID:
- {{ record?.id }}
-
-
- Nama:
- {{ record.name }}
-
-
- Kode:
- {{ record.code }}
-
-
-
+
diff --git a/app/components/content/device-order/main.vue b/app/components/content/device-order/main.vue
index ae5a9ca8..ff8722de 100644
--- a/app/components/content/device-order/main.vue
+++ b/app/components/content/device-order/main.vue
@@ -3,10 +3,14 @@
import List from './list.vue'
import Entry from './entry.vue'
-const { mode } = useQueryMode()
+defineProps<{
+ encounter_id: number
+}>()
+
+const { mode } = useQueryCRUDMode()
-
-
+
+
diff --git a/app/components/content/document-upload/add.vue b/app/components/content/document-upload/add.vue
new file mode 100644
index 00000000..9d099189
--- /dev/null
+++ b/app/components/content/document-upload/add.vue
@@ -0,0 +1,128 @@
+
+
+
+
+ Upload Dokumen
+
+
+
+
+
+
+
+
+
diff --git a/app/components/content/document-upload/edit.vue b/app/components/content/document-upload/edit.vue
new file mode 100644
index 00000000..c4033fb2
--- /dev/null
+++ b/app/components/content/document-upload/edit.vue
@@ -0,0 +1,134 @@
+
+
+
+
+ Upload Dokumen
+
+
+
+
+
+
+
+
+
diff --git a/app/components/content/document-upload/list.vue b/app/components/content/document-upload/list.vue
new file mode 100644
index 00000000..d1f6fbad
--- /dev/null
+++ b/app/components/content/document-upload/list.vue
@@ -0,0 +1,183 @@
+
+
+
+
+
+
+
+
+
+
+ ID:
+ {{ record?.id }}
+
+
+ Nama:
+ {{ record?.name }}
+
+
+
+
+
+
+
diff --git a/app/components/content/encounter/process.vue b/app/components/content/encounter/process.vue
index 23640af7..a6bd32dd 100644
--- a/app/components/content/encounter/process.vue
+++ b/app/components/content/encounter/process.vue
@@ -9,15 +9,21 @@ import { getDetail } from '~/services/encounter.service'
import type { TabItem } from '~/components/pub/my-ui/comp-tab/type'
import CompTab from '~/components/pub/my-ui/comp-tab/comp-tab.vue'
+import { genEncounter } from '~/models/encounter'
+
// PLASE ORDER BY TAB POSITION
import Status from '~/components/content/encounter/status.vue'
import AssesmentFunctionList from '~/components/content/soapi/entry.vue'
import EarlyMedicalAssesmentList from '~/components/content/soapi/entry.vue'
import EarlyMedicalRehabList from '~/components/content/soapi/entry.vue'
+import DeviceOrder from '~/components/content/device-order/main.vue'
import Prescription from '~/components/content/prescription/main.vue'
import CpLabOrder from '~/components/content/cp-lab-order/main.vue'
import Radiology from '~/components/content/radiology-order/main.vue'
import Consultation from '~/components/content/consultation/list.vue'
+import DocUploadList from '~/components/content/document-upload/list.vue'
+import GeneralConsentList from '~/components/content/general-consent/entry.vue'
+import ResumeList from '~/components/content/resume/list.vue'
import ControlLetterList from '~/components/content/control-letter/list.vue'
const route = useRoute()
@@ -32,12 +38,18 @@ const activeTab = computed({
})
const id = typeof route.params.id == 'string' ? parseInt(route.params.id) : 0
-const dataRes = await getDetail(id, {
- includes:
- 'patient,patient-person,patient-person-addresses,unit,Appointment_Doctor,Appointment_Doctor-employee,Appointment_Doctor-employee-person',
+const data = ref(genEncounter())
+
+async function fetchDetail() {
+ const res = await getDetail(id, {
+ includes: 'patient,patient-person,patient-person-addresses,unit,Appointment_Doctor,Appointment_Doctor-employee,Appointment_Doctor-employee-person,EncounterDocuments',
+ })
+ if(res.body?.data) data.value = res.body?.data
+}
+
+onMounted(() => {
+ fetchDetail()
})
-const dataResBody = dataRes.body ?? null
-const data = dataResBody?.data ?? null
const tabs: TabItem[] = [
{ value: 'status', label: 'Status Masuk/Keluar', component: Status, props: { encounter: data } },
@@ -61,21 +73,23 @@ const tabs: TabItem[] = [
},
{ value: 'therapy-protocol', label: 'Protokol Terapi' },
{ value: 'education-assessment', label: 'Asesmen Kebutuhan Edukasi' },
- { value: 'consent', label: 'General Consent' },
+ { value: 'consent', label: 'General Consent', component: GeneralConsentList, props: { encounter: data } },
{ value: 'patient-note', label: 'CPRJ' },
- { value: 'prescription', label: 'Order Obat', component: Prescription, props: { encounter_id: data.id } },
- { value: 'device', label: 'Order Alkes' },
- { value: 'mcu-radiology', label: 'Order Radiologi', component: Radiology, props: { encounter_id: data.id } },
- { value: 'mcu-lab-cp', label: 'Order Lab PK', component: CpLabOrder, props: { encounter_id: data.id } },
+ { value: 'prescription', label: 'Order Obat', component: Prescription, props: { encounter_id: data.value.id } },
+ { value: 'device-order', label: 'Order Alkes', component: DeviceOrder, props: { encounter_id: data.value.id } },
+ { value: 'mcu-radiology', label: 'Order Radiologi', component: Radiology, props: { encounter_id: data.value.id } },
+ { value: 'mcu-lab-cp', label: 'Order Lab PK', component: CpLabOrder, props: { encounter_id: data.value.id } },
{ value: 'mcu-lab-micro', label: 'Order Lab Mikro' },
{ value: 'mcu-lab-pa', label: 'Order Lab PA' },
{ value: 'medical-action', label: 'Order Ruang Tindakan' },
{ value: 'mcu-result', label: 'Hasil Penunjang' },
{ value: 'consultation', label: 'Konsultasi', component: Consultation, props: { encounter: data } },
+ { value: 'resume', label: 'Resume', component: ResumeList, props: { encounter: data } },
+ { value: 'control', label: 'Surat Kontrol' },
{ value: 'resume', label: 'Resume' },
{ value: 'control', label: 'Surat Kontrol', component: ControlLetterList, props: { encounter: data } },
{ value: 'screening', label: 'Skrinning MPP' },
- { value: 'supporting-document', label: 'Upload Dokumen Pendukung' },
+ { value: 'supporting-document', label: 'Upload Dokumen Pendukung', component: DocUploadList, props: { encounter: data }, },
]
diff --git a/app/components/content/equipment/list.vue b/app/components/content/equipment/list.vue
index 19e5d913..0db6034c 100644
--- a/app/components/content/equipment/list.vue
+++ b/app/components/content/equipment/list.vue
@@ -110,6 +110,7 @@ watch([recId, recAction], () => {
getCurrentMaterialDetail(recId.value)
title.value = 'Edit Perlengkapan'
isReadonly.value = false
+ isFormEntryDialogOpen.value = true
break
case ActionEvents.showConfirmDelete:
isRecordConfirmationOpen.value = true
@@ -158,7 +159,7 @@ onMounted(async () => {
@submit="
(values: MaterialFormData, resetForm: any) => {
if (recId > 0) {
- handleActionEdit(recId, values, getEquipmentList, resetForm, toast)
+ handleActionEdit(recItem.code, values, getEquipmentList, resetForm, toast)
return
}
handleActionSave(values, getEquipmentList, resetForm, toast)
@@ -173,7 +174,7 @@ onMounted(async () => {
v-model:open="isRecordConfirmationOpen"
action="delete"
:record="recItem"
- @confirm="() => handleActionRemove(recId, getEquipmentList, toast)"
+ @confirm="() => handleActionRemove(recItem.code, getEquipmentList, toast)"
@cancel=""
>
diff --git a/app/components/content/general-consent/entry.vue b/app/components/content/general-consent/entry.vue
new file mode 100644
index 00000000..5769e967
--- /dev/null
+++ b/app/components/content/general-consent/entry.vue
@@ -0,0 +1,36 @@
+
+
+
+
+
+
+
+
diff --git a/app/components/content/general-consent/form.vue b/app/components/content/general-consent/form.vue
new file mode 100644
index 00000000..738adca1
--- /dev/null
+++ b/app/components/content/general-consent/form.vue
@@ -0,0 +1,185 @@
+
+
+
+
+
+
diff --git a/app/components/content/general-consent/list.vue b/app/components/content/general-consent/list.vue
new file mode 100644
index 00000000..4cf269ee
--- /dev/null
+++ b/app/components/content/general-consent/list.vue
@@ -0,0 +1,179 @@
+
+
+
+
+
+
+
+
+ handleActionRemove(recId, getMyList, toast)"
+ @cancel=""
+ >
+
+
+
+ ID:
+ {{ record?.id }}
+
+
+ Nama:
+ {{ record.name }}
+
+
+ Kode:
+ {{ record.code }}
+
+
+
+
+
diff --git a/app/components/content/medicine-form/list.vue b/app/components/content/medicine-form/list.vue
new file mode 100644
index 00000000..1ca9eefe
--- /dev/null
+++ b/app/components/content/medicine-form/list.vue
@@ -0,0 +1,193 @@
+
+
+
+
+
+
+
+
+
+
+ handleActionRemove(recItem.code, getMedicineFormList, toast)"
+ @cancel=""
+ >
+
+
+
+ ID:
+ {{ record?.id }}
+
+
+ Nama:
+ {{ record.name }}
+
+
+ Kode:
+ {{ record.code }}
+
+
+
+
+
diff --git a/app/components/content/medicine-group/list.vue b/app/components/content/medicine-group/list.vue
index 80faf1ab..6c695d72 100644
--- a/app/components/content/medicine-group/list.vue
+++ b/app/components/content/medicine-group/list.vue
@@ -108,6 +108,7 @@ watch([recId, recAction], () => {
getCurrentMedicineGroupDetail(recId.value)
title.value = 'Edit Kelompok Obat'
isReadonly.value = false
+ isFormEntryDialogOpen.value = true
break
case ActionEvents.showConfirmDelete:
isRecordConfirmationOpen.value = true
@@ -154,7 +155,7 @@ onMounted(async () => {
@submit="
(values: BaseFormData | Record, resetForm: () => void) => {
if (recId > 0) {
- handleActionEdit(recId, values, getMedicineGroupList, resetForm, toast)
+ handleActionEdit(recItem.code, values, getMedicineGroupList, resetForm, toast)
return
}
handleActionSave(values, getMedicineGroupList, resetForm, toast)
@@ -169,7 +170,7 @@ onMounted(async () => {
v-model:open="isRecordConfirmationOpen"
action="delete"
:record="recItem"
- @confirm="() => handleActionRemove(recId, getMedicineGroupList, toast)"
+ @confirm="() => handleActionRemove(recItem.code, getMedicineGroupList, toast)"
@cancel=""
>
diff --git a/app/components/content/medicine-method/list.vue b/app/components/content/medicine-method/list.vue
index 9e0e5d01..2c8fb8c6 100644
--- a/app/components/content/medicine-method/list.vue
+++ b/app/components/content/medicine-method/list.vue
@@ -108,6 +108,7 @@ watch([recId, recAction], () => {
getCurrentMedicineMethodDetail(recId.value)
title.value = 'Edit Metode Obat'
isReadonly.value = false
+ isFormEntryDialogOpen.value = true
break
case ActionEvents.showConfirmDelete:
isRecordConfirmationOpen.value = true
@@ -154,7 +155,7 @@ onMounted(async () => {
@submit="
(values: BaseFormData | Record, resetForm: () => void) => {
if (recId > 0) {
- handleActionEdit(recId, values, getMedicineMethodList, resetForm, toast)
+ handleActionEdit(recItem.code, values, getMedicineMethodList, resetForm, toast)
return
}
handleActionSave(values, getMedicineMethodList, resetForm, toast)
@@ -169,7 +170,7 @@ onMounted(async () => {
v-model:open="isRecordConfirmationOpen"
action="delete"
:record="recItem"
- @confirm="() => handleActionRemove(recId, getMedicineMethodList, toast)"
+ @confirm="() => handleActionRemove(recItem.code, getMedicineMethodList, toast)"
@cancel=""
>
diff --git a/app/components/content/medicine/list.vue b/app/components/content/medicine/list.vue
index 27470776..bfbf8750 100644
--- a/app/components/content/medicine/list.vue
+++ b/app/components/content/medicine/list.vue
@@ -37,10 +37,12 @@ import {
import { getList, getDetail } from '~/services/medicine.service'
import { getValueLabelList as getMedicineGroupList } from '~/services/medicine-group.service'
import { getValueLabelList as getMedicineMethodList } from '~/services/medicine-method.service'
+import { getValueLabelList as getMedicineFormList } from '~/services/medicine-form.service'
import { getValueLabelList as getUomList } from '~/services/uom.service'
const medicineGroups = ref<{ value: string; label: string }[]>([])
const medicineMethods = ref<{ value: string; label: string }[]>([])
+const medicineForms = ref<{ value: string; label: string }[]>([])
const uoms = ref<{ value: string; label: string }[]>([])
const title = ref('')
@@ -59,7 +61,7 @@ const {
sort: 'createdAt:asc',
'page-number': params['page-number'] || 0,
'page-size': params['page-size'] || 10,
- includes: 'medicineGroup,medicineMethod,uom',
+ includes: 'medicineGroup,medicineMethod,medicineForm,uom',
})
return { success: result.success || false, body: result.body || {} }
},
@@ -116,6 +118,7 @@ watch([recId, recAction], () => {
case ActionEvents.showEdit:
getCurrentMedicineDetail(recId.value)
title.value = 'Edit Obat'
+ isFormEntryDialogOpen.value = true
isReadonly.value = false
break
case ActionEvents.showConfirmDelete:
@@ -127,6 +130,7 @@ watch([recId, recAction], () => {
onMounted(async () => {
medicineGroups.value = await getMedicineGroupList({ sort: 'createdAt:asc', 'page-size': 100 })
medicineMethods.value = await getMedicineMethodList({ sort: 'createdAt:asc', 'page-size': 100 })
+ medicineForms.value = await getMedicineFormList({ sort: 'createdAt:asc', 'page-size': 100 })
uoms.value = await getUomList({ sort: 'createdAt:asc', 'page-size': 100 })
await getMedicineList()
})
@@ -163,13 +167,14 @@ onMounted(async () => {
:values="recItem"
:medicineGroups="medicineGroups"
:medicineMethods="medicineMethods"
+ :medicineForms="medicineForms"
:uoms="uoms"
:is-loading="isProcessing"
:is-readonly="isReadonly"
@submit="
(values: MedicineFormData | Record, resetForm: () => void) => {
if (recId > 0) {
- handleActionEdit(recId, values, getMedicineList, resetForm, toast)
+ handleActionEdit(recItem.code, values, getMedicineList, resetForm, toast)
return
}
handleActionSave(values, getMedicineList, resetForm, toast)
@@ -184,7 +189,7 @@ onMounted(async () => {
v-model:open="isRecordConfirmationOpen"
action="delete"
:record="recItem"
- @confirm="() => handleActionRemove(recId, getMedicineList, toast)"
+ @confirm="() => handleActionRemove(recItem.code, getMedicineList, toast)"
@cancel=""
>
diff --git a/app/components/content/prescription/entry.vue b/app/components/content/prescription/entry.vue
index 4b3fa663..46768432 100644
--- a/app/components/content/prescription/entry.vue
+++ b/app/components/content/prescription/entry.vue
@@ -1,86 +1,215 @@
@@ -91,42 +220,147 @@ function saveNonMix(data: PrescriptionItem) {
class="mb-4 xl:mb-5"
/>
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ handleActionRemove(recId, getPrescriptionItems, toast)"
+ @cancel=""
+ >
+
+
+
+ ID:
+ {{ record?.id }}
+
+
+ Nama:
+ {{ record.name }}
+
+
+ Kode:
+ {{ record.code }}
+
+
+
+
diff --git a/app/components/content/prescription/list.vue b/app/components/content/prescription/list.vue
index 844cb04f..afd012f6 100644
--- a/app/components/content/prescription/list.vue
+++ b/app/components/content/prescription/list.vue
@@ -1,8 +1,10 @@
-
+
+
+
+
+
+
handleActionRemove(recId, getMyList, toast)"
@cancel=""
>
+
+ Tanggal
+ :
+ {{ recItem.createdAt.substring(0, 10) }}
+
+
+ DPJP
+ :
+ {{ recItem.doctor?.employee?.person?.name }}
+
+
+
+ handleActionSubmit(recId, getMyList, toast)"
+ @cancel=""
+ >
+
+ Tanggal
+ :
+ {{ recItem.createdAt.substring(0, 10) }}
+
+
+ DPJP
+ :
+ {{ recItem.doctor?.employee?.person?.name }}
+
diff --git a/app/components/content/resume/add.vue b/app/components/content/resume/add.vue
new file mode 100644
index 00000000..6fda4bf8
--- /dev/null
+++ b/app/components/content/resume/add.vue
@@ -0,0 +1,200 @@
+
+
+
+ Tambah Resume
+
+
+
+
+
+
+
+
+ aaaaaaaaaaaaaaa
+
+
+
+
+
+
+
+
diff --git a/app/components/content/resume/list.vue b/app/components/content/resume/list.vue
new file mode 100644
index 00000000..4b5b5001
--- /dev/null
+++ b/app/components/content/resume/list.vue
@@ -0,0 +1,215 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/app/components/content/tools/list.vue b/app/components/content/tools/list.vue
index da22a976..4f50199f 100644
--- a/app/components/content/tools/list.vue
+++ b/app/components/content/tools/list.vue
@@ -163,7 +163,7 @@ onMounted(async () => {
@submit="
(values: DeviceFormData, resetForm: any) => {
if (recId > 0) {
- handleActionEdit(recId, values, getToolsList, resetForm, toast)
+ handleActionEdit(recItem.code, values, getToolsList, resetForm, toast)
return
}
handleActionSave(values, getToolsList, resetForm, toast)
@@ -178,7 +178,7 @@ onMounted(async () => {
v-model:open="isRecordConfirmationOpen"
action="delete"
:record="recItem"
- @confirm="() => handleActionRemove(recId, getToolsList, toast)"
+ @confirm="() => handleActionRemove(recItem.code, getToolsList, toast)"
@cancel=""
>
diff --git a/app/components/pub/my-ui/confirmation/confirmation.vue b/app/components/pub/my-ui/confirmation/confirmation.vue
index b5c328aa..928d7827 100644
--- a/app/components/pub/my-ui/confirmation/confirmation.vue
+++ b/app/components/pub/my-ui/confirmation/confirmation.vue
@@ -8,6 +8,8 @@ interface ConfirmationProps {
message?: string
confirmText?: string
cancelText?: string
+ noTrueSlot?: boolean
+ skipClosingMessage?: boolean
variant?: 'default' | 'destructive' | 'warning'
size?: 'sm' | 'md' | 'lg' | 'xl'
}
@@ -71,20 +73,22 @@ function handleCancel() {
|