Feat Infra (#108)

* fix: adjustment some schemas

* fix(room): fixing integrate unit of room

* feat(warehouse): modify form and integration

* feat(counter): modify form and integration

* feat(screen): add list, form and integration

* feat(screen): add page for public screen

* fix: add on reset state at list

* fix: solve list of relation

* feat(chamber): integrate form to api chamber

* feat(bed): integrate form to api bed

* fix: add searching function on list service

* fix: rewrite style for dropdown and tree select

* fix: add sort params

* fix: add sort params on division + medicine

* feat(division-position): layouting form + list

* fix: add sort params for getValueList

* chore: modify side menu style

* chore: fix ui dashboard

* feat(division-position): add content list

* feat(division-position): add temporary page

* feat(division-position): modify content and entry form
This commit is contained in:
Muhammad Rifai
2025-10-10 20:36:07 +07:00
committed by GitHub
parent 4f0c1f4318
commit f94b6d273a
73 changed files with 2638 additions and 416 deletions
+11 -1
View File
@@ -13,6 +13,7 @@ import { toast } from '~/components/pub/ui/toast'
// Types
import { ActionEvents, type HeaderPrep } from '~/components/pub/my-ui/data/types'
import { DivisionSchema, type DivisionFormData } from '~/schemas/division.schema'
import type { Division } from "~/models/division"
import type { TreeItem } from '~/models/_base'
// Handlers
@@ -24,6 +25,7 @@ import {
isProcessing,
isFormEntryDialogOpen,
isRecordConfirmationOpen,
onResetState,
handleActionSave,
handleActionEdit,
handleActionRemove,
@@ -48,6 +50,7 @@ const {
fetchFn: async (params: any) => {
const result = await getList({
search: params.search,
sort: 'createdAt:asc',
'page-number': params['page-number'] || 0,
'page-size': params['page-size'] || 10,
includes: 'parent,childrens',
@@ -127,7 +130,8 @@ watch(
})
if (result.success) {
const currentData = result.body.data || []
divisionsTrees.value = getValueTreeItems(currentData || [])
const normalizedData = currentData.filter((division: Division) => !division.parent_id)
divisionsTrees.value = getValueTreeItems(normalizedData)
}
},
)
@@ -156,6 +160,12 @@ onMounted(async () => {
:title="!!recItem ? title : 'Tambah Divisi'"
size="lg"
prevent-outside
@update:open="
(value: any) => {
onResetState()
isFormEntryDialogOpen = value
}
"
>
<AppDivisionEntryForm
:schema="DivisionSchema"