feat(sep): add class form

This commit is contained in:
riefive
2025-10-23 12:15:55 +07:00
parent 891c67d6ff
commit 7f0e7bee4a
5 changed files with 318 additions and 103 deletions
+21
View File
@@ -20,6 +20,9 @@ import {
supportCodes,
procedureTypes,
purposeOfVisits,
classLevels,
classLevelUpgrades,
classPaySources,
} from '~/lib/constants.vclaim'
// Services
@@ -60,6 +63,9 @@ const assessmentsList = ref<Array<{ value: string; label: string }>>([])
const provincesList = ref<Array<{ value: string; label: string }>>([])
const citiesList = ref<Array<{ value: string; label: string }>>([])
const districtsList = ref<Array<{ value: string; label: string }>>([])
const classLevelsList = ref<Array<{ value: string; label: string }>>([])
const classLevelUpgradesList = ref<Array<{ value: string; label: string }>>([])
const classPaySourcesList = ref<Array<{ value: string; label: string }>>([])
const isPatientsLoading = ref(false)
const paginationMeta = ref<PaginationMeta>({
recordCount: 0,
@@ -341,6 +347,18 @@ async function handleInit() {
value: item.toString(),
label: `${item.toString()} - ${supportCodes[item]}`,
})) as any
classLevelsList.value = Object.keys(classLevels).map((item) => ({
value: item.toString(),
label: classLevels[item],
})) as any
classLevelUpgradesList.value = Object.keys(classLevelUpgrades).map((item) => ({
value: item.toString(),
label: classLevelUpgrades[item],
})) as any
classPaySourcesList.value = Object.keys(classPaySources).map((item) => ({
value: item.toString(),
label: classPaySources[item],
})) as any
}
onMounted(async () => {
@@ -376,6 +394,9 @@ onMounted(async () => {
:provinces="provincesList"
:cities="citiesList"
:districts="districtsList"
:class-levels="classLevelsList"
:class-level-upgrades="classLevelUpgradesList"
:class-pay-sources="classPaySourcesList"
:patient="selectedPatientObject"
@fetch="handleFetch"
@event="handleEvent"