diff --git a/app/components/app/cemotherapy/dialog-verification.vue b/app/components/app/chemotherapy/dialog-verification.vue
similarity index 100%
rename from app/components/app/cemotherapy/dialog-verification.vue
rename to app/components/app/chemotherapy/dialog-verification.vue
diff --git a/app/components/app/cemotherapy/entry-form.vue b/app/components/app/chemotherapy/entry-form.vue
similarity index 98%
rename from app/components/app/cemotherapy/entry-form.vue
rename to app/components/app/chemotherapy/entry-form.vue
index 3a4104b8..39113d63 100644
--- a/app/components/app/cemotherapy/entry-form.vue
+++ b/app/components/app/chemotherapy/entry-form.vue
@@ -13,7 +13,7 @@ import DatepickerSingle from '~/components/pub/my-ui/datepicker/datepicker-singl
import type z from 'zod'
import { useForm } from 'vee-validate'
import { toTypedSchema } from '@vee-validate/zod'
-import { cemotherapySchema } from "~/schemas/cemotherapy.schema"
+import { chemotherapySchema } from "~/schemas/chemotherapy.schema"
interface Props {
values?: any
@@ -37,7 +37,7 @@ const emit = defineEmits<{
}>()
const { defineField, errors, meta } = useForm({
- validationSchema: toTypedSchema(cemotherapySchema),
+ validationSchema: toTypedSchema(chemotherapySchema),
initialValues: {
namaPasien: '',
tanggalLahir: '',
diff --git a/app/components/app/chemotherapy/list-cfg.medicine.ts b/app/components/app/chemotherapy/list-cfg.medicine.ts
new file mode 100644
index 00000000..103452f5
--- /dev/null
+++ b/app/components/app/chemotherapy/list-cfg.medicine.ts
@@ -0,0 +1,69 @@
+import type { Config, RecComponent } from '~/components/pub/my-ui/data-table'
+import { defineAsyncComponent } from 'vue'
+
+type SmallDetailDto = any
+
+const action = defineAsyncComponent(() => import('~/components/pub/my-ui/data/dropdown-action-dud.vue'))
+
+export const config: Config = {
+ cols: [
+ { width: 60 },
+ { width: 200 },
+ { width: 100 },
+ { width: 100 },
+ { width: 150 },
+ { width: 80 },
+ { width: 200 },
+ { width: 120 },
+ ],
+
+ headers: [
+ [
+ { label: 'NO.' },
+ { label: 'NAMA OBAT' },
+ { label: 'DOSIS' },
+ { label: 'SATUAN' },
+ { label: 'RUTE PEMBERIAN' },
+ { label: 'HARI' },
+ { label: 'CATATAN' },
+ { label: '' },
+ ],
+ ],
+
+ keys: [
+ 'number',
+ 'namaObat',
+ 'dosis',
+ 'satuan',
+ 'rute',
+ 'hari',
+ 'catatan',
+ 'action',
+ ],
+
+ delKeyNames: [
+ { key: 'code', label: 'Kode' },
+ { key: 'name', label: 'Nama' },
+ ],
+
+ parses: {
+ 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,
+ }
+ return res
+ },
+ },
+
+ htmls: {},
+}
+
diff --git a/app/components/app/cemotherapy/list-cfg.protocol.ts b/app/components/app/chemotherapy/list-cfg.protocol.ts
similarity index 100%
rename from app/components/app/cemotherapy/list-cfg.protocol.ts
rename to app/components/app/chemotherapy/list-cfg.protocol.ts
diff --git a/app/components/app/cemotherapy/list-cfg.ts b/app/components/app/chemotherapy/list-cfg.ts
similarity index 100%
rename from app/components/app/cemotherapy/list-cfg.ts
rename to app/components/app/chemotherapy/list-cfg.ts
diff --git a/app/components/app/cemotherapy/list-cfg.visit.ts b/app/components/app/chemotherapy/list-cfg.visit.ts
similarity index 100%
rename from app/components/app/cemotherapy/list-cfg.visit.ts
rename to app/components/app/chemotherapy/list-cfg.visit.ts
diff --git a/app/components/app/chemotherapy/list.medicine.vue b/app/components/app/chemotherapy/list.medicine.vue
new file mode 100644
index 00000000..748c8cb9
--- /dev/null
+++ b/app/components/app/chemotherapy/list.medicine.vue
@@ -0,0 +1,76 @@
+
+
+
+
+
+
+
+
+
Protokol Obat Kemoterapi
+
Daftar obat-obatan yang digunakan dalam protokol kemoterapi.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/components/app/cemotherapy/list.protocol.vue b/app/components/app/chemotherapy/list.protocol.vue
similarity index 100%
rename from app/components/app/cemotherapy/list.protocol.vue
rename to app/components/app/chemotherapy/list.protocol.vue
diff --git a/app/components/app/cemotherapy/list.register.vue b/app/components/app/chemotherapy/list.register.vue
similarity index 100%
rename from app/components/app/cemotherapy/list.register.vue
rename to app/components/app/chemotherapy/list.register.vue
diff --git a/app/components/app/cemotherapy/list.visit.vue b/app/components/app/chemotherapy/list.visit.vue
similarity index 100%
rename from app/components/app/cemotherapy/list.visit.vue
rename to app/components/app/chemotherapy/list.visit.vue
diff --git a/app/components/app/cemotherapy/list.vue b/app/components/app/chemotherapy/list.vue
similarity index 100%
rename from app/components/app/cemotherapy/list.vue
rename to app/components/app/chemotherapy/list.vue
diff --git a/app/components/app/cemotherapy/sample.ts b/app/components/app/chemotherapy/sample.ts
similarity index 92%
rename from app/components/app/cemotherapy/sample.ts
rename to app/components/app/chemotherapy/sample.ts
index 24b9ebbf..082cde66 100644
--- a/app/components/app/cemotherapy/sample.ts
+++ b/app/components/app/chemotherapy/sample.ts
@@ -1,4 +1,4 @@
-export type CemotherapyData = {
+export type ChemotherapyData = {
id: number
tanggal: string
noRm: string
@@ -14,7 +14,7 @@ export type CemotherapyData = {
asal: string
}
-export const sampleRows: CemotherapyData[] = [
+export const sampleRows: ChemotherapyData[] = [
{
id: 1,
tanggal: '12 Agustus 2025',
diff --git a/app/components/app/cemotherapy/status-badge.vue b/app/components/app/chemotherapy/status-badge.vue
similarity index 100%
rename from app/components/app/cemotherapy/status-badge.vue
rename to app/components/app/chemotherapy/status-badge.vue
diff --git a/app/components/app/cemotherapy/verify-button.vue b/app/components/app/chemotherapy/verify-button.vue
similarity index 100%
rename from app/components/app/cemotherapy/verify-button.vue
rename to app/components/app/chemotherapy/verify-button.vue
diff --git a/app/components/content/cemotherapy/list.vue b/app/components/content/chemotherapy/list.vue
similarity index 88%
rename from app/components/content/cemotherapy/list.vue
rename to app/components/content/chemotherapy/list.vue
index 957a827f..d4104f03 100644
--- a/app/components/content/cemotherapy/list.vue
+++ b/app/components/content/chemotherapy/list.vue
@@ -2,10 +2,10 @@
import { ref, computed } from 'vue'
// Components
-import AppCemotherapyList from '~/components/app/cemotherapy/list.vue'
+import AppChemotherapyList from '~/components/app/chemotherapy/list.vue'
// Samples
-import { sampleRows, type CemotherapyData } from '~/components/app/cemotherapy/sample'
+import { sampleRows, type ChemotherapyData } from '~/components/app/chemotherapy/sample'
const search = ref('')
const dateFrom = ref('')
@@ -14,7 +14,7 @@ const dateTo = ref('')
// filter + pencarian sederhana (client-side)
const filtered = computed(() => {
const q = search.value.trim().toLowerCase()
- return sampleRows.filter((r: CemotherapyData) => {
+ return sampleRows.filter((r: ChemotherapyData) => {
if (q) {
return r.nama.toLowerCase().includes(q) || r.noRm.toLowerCase().includes(q) || r.dokter.toLowerCase().includes(q)
}
@@ -59,7 +59,7 @@ const filtered = computed(() => {
-
+//
+import { computed } from 'vue'
+import { useRoute, useRouter } from 'vue-router'
+
+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'
+
+// PLASE ORDER BY TAB POSITION
+import ProtocolList from '~/components/app/chemotherapy/list.protocol.vue'
+import MedicineProtocolList from '~/components/app/chemotherapy/list.medicine.vue'
+
+const route = useRoute()
+const router = useRouter()
+
+// activeTab selalu sinkron dengan query param
+const activeTab = computed({
+ get: () => (route.query?.tab && typeof route.query.tab === 'string' ? route.query.tab : 'chemotherapy-protocol'),
+ set: (val: string) => {
+ router.replace({ path: route.path, query: { tab: val } })
+ },
+})
+
+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 dataResBody = dataRes.body ?? null
+const data = dataResBody?.data ?? null
+
+// Dummy rows for ProtocolList (matches keys expected by list-cfg.protocol)
+const protocolRows = [
+ {
+ number: '1',
+ tanggal: new Date().toISOString().substring(0, 10),
+ siklus: 'I',
+ periode: 'Siklus I',
+ kehadiran: 'Hadir',
+ action: '',
+ },
+ {
+ number: '2',
+ tanggal: new Date().toISOString().substring(0, 10),
+ siklus: 'II',
+ periode: 'Siklus II',
+ kehadiran: 'Tidak Hadir',
+ action: '',
+ },
+]
+
+const paginationMeta = {
+ recordCount: protocolRows.length,
+ page: 1,
+ pageSize: 10,
+ totalPage: 1,
+ hasNext: false,
+ hasPrev: false,
+}
+
+const tabs: TabItem[] = [
+ { value: 'chemotherapy-protocol', label: 'Protokol Kemoterapi', component: ProtocolList, props: { data: protocolRows, paginationMeta } },
+ { value: 'chemotherapy-medicine', label: 'Protokol Obat Kemoterapi', component: MedicineProtocolList, props: { data: protocolRows, paginationMeta } },
+]
+
+
+
+
+
+
diff --git a/app/components/content/cemotherapy/protocol.vue b/app/components/content/chemotherapy/protocol.vue
similarity index 90%
rename from app/components/content/cemotherapy/protocol.vue
rename to app/components/content/chemotherapy/protocol.vue
index 427b4642..82050d79 100644
--- a/app/components/content/cemotherapy/protocol.vue
+++ b/app/components/content/chemotherapy/protocol.vue
@@ -8,7 +8,7 @@ import type { PaginationMeta } from '~/components/pub/my-ui/pagination/paginatio
// Components
import CompTab from '~/components/pub/my-ui/comp-tab/comp-tab.vue'
-import ProtocolList from '~/components/app/cemotherapy/list.protocol.vue'
+import ProtocolList from '~/components/app/chemotherapy/list.protocol.vue'
// Services
import { getDetail } from '~/services/encounter.service'
@@ -76,8 +76,8 @@ const paginationMeta: PaginationMeta = {
}
const tabs: TabItem[] = [
- { value: 'cemotherapy-protocol', label: 'Protokol Kemoterapi', component: ProtocolList, props: { data: protocolRows, paginationMeta } },
- { value: 'cemotherapy-medicine', label: 'Protokol Obat Kemoterapi' },
+ { value: 'chemotherapy-protocol', label: 'Protokol Kemoterapi', component: ProtocolList, props: { data: protocolRows, paginationMeta } },
+ { value: 'chemotherapy-medicine', label: 'Protokol Obat Kemoterapi' },
]
onMounted(async () => {
diff --git a/app/pages/(features)/outpatient-action/chemotherapy/[id]/index.vue b/app/pages/(features)/outpatient-action/chemotherapy/[id]/index.vue
new file mode 100644
index 00000000..edc1cd02
--- /dev/null
+++ b/app/pages/(features)/outpatient-action/chemotherapy/[id]/index.vue
@@ -0,0 +1,42 @@
+
+
+
+
+
+
+
+
+
diff --git a/app/pages/(features)/outpatient-action/chemotherapy/index.vue b/app/pages/(features)/outpatient-action/chemotherapy/index.vue
new file mode 100644
index 00000000..4dd31ebe
--- /dev/null
+++ b/app/pages/(features)/outpatient-action/chemotherapy/index.vue
@@ -0,0 +1,9 @@
+
+
+
+
+
diff --git a/app/pages/(features)/outpation-action/cemotherapy/list.vue b/app/pages/(features)/outpatient-action/chemotherapy/list.vue
similarity index 96%
rename from app/pages/(features)/outpation-action/cemotherapy/list.vue
rename to app/pages/(features)/outpatient-action/chemotherapy/list.vue
index 02326343..a141baaa 100644
--- a/app/pages/(features)/outpation-action/cemotherapy/list.vue
+++ b/app/pages/(features)/outpatient-action/chemotherapy/list.vue
@@ -33,7 +33,7 @@ const canRead = true // hasReadAccess(roleAccess)
diff --git a/app/pages/(features)/outpation-action/cemotherapy/index.vue b/app/pages/(features)/outpation-action/cemotherapy/index.vue
deleted file mode 100644
index 06da4369..00000000
--- a/app/pages/(features)/outpation-action/cemotherapy/index.vue
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
diff --git a/app/schemas/cemotherapy.schema.ts b/app/schemas/chemotherapy.schema.ts
similarity index 97%
rename from app/schemas/cemotherapy.schema.ts
rename to app/schemas/chemotherapy.schema.ts
index df00c200..212e5358 100644
--- a/app/schemas/cemotherapy.schema.ts
+++ b/app/schemas/chemotherapy.schema.ts
@@ -2,7 +2,7 @@ import { z } from 'zod'
const dateStringSchema = z.string().min(1)
-export const cemotherapySchema = z.object({
+export const chemotherapySchema = z.object({
// Data Pasien
namaPasien: z.string({
required_error: 'Nama pasien harus diisi',
diff --git a/public/side-menu-items/doc.json b/public/side-menu-items/doc.json
index e3ab2cdf..a0c8aa7d 100644
--- a/public/side-menu-items/doc.json
+++ b/public/side-menu-items/doc.json
@@ -84,7 +84,7 @@
{
"title": "Kemoterapi",
"icon": "i-lucide-droplets",
- "link": "/outpatient-action/cemotherapy"
+ "link": "/outpatient-action/chemotherapy"
},
{
"title": "Hemofilia",
diff --git a/public/side-menu-items/nur.json b/public/side-menu-items/nur.json
index 8185456c..ca5a6108 100644
--- a/public/side-menu-items/nur.json
+++ b/public/side-menu-items/nur.json
@@ -63,7 +63,7 @@
{
"title": "Kemoterapi",
"icon": "i-lucide-droplets",
- "link": "/outpation-action/cemotherapy"
+ "link": "/outpatient-action/chemotherapy"
},
{
"title": "Hemofilia",
diff --git a/public/side-menu-items/nut.json b/public/side-menu-items/nut.json
index 4368b22e..0de1a113 100644
--- a/public/side-menu-items/nut.json
+++ b/public/side-menu-items/nut.json
@@ -35,7 +35,7 @@
{
"title": "Kemoterapi",
"icon": "i-lucide-droplets",
- "link": "/outpatient-action/cemotherapy"
+ "link": "/outpatient-action/chemotherapy"
},
{
"title": "Hemofilia",
diff --git a/public/side-menu-items/sys.json b/public/side-menu-items/sys.json
index 19491069..1e11655c 100644
--- a/public/side-menu-items/sys.json
+++ b/public/side-menu-items/sys.json
@@ -139,7 +139,7 @@
{
"title": "Kemoterapi",
"icon": "i-lucide-droplets",
- "link": "/outpation-action/cemotherapy"
+ "link": "/outpatient-action/chemotherapy"
},
{
"title": "Hemofilia",