From bf441ff71449506dc396027402aaf819dec4c136 Mon Sep 17 00:00:00 2001 From: Khafid Prayoga Date: Thu, 30 Oct 2025 14:10:40 +0700 Subject: [PATCH] refactor(components): change ID types from string to number and update related components - Update installation and unit detail components to use number type for IDs - Modify route parameter handling to pass numbers instead of strings - Add new unit position entry detail component with proper type handling --- .../app/unit-position/entry-detail.vue | 192 ++++++++++++++++++ .../content/installation/detail.vue | 2 +- app/components/content/unit/detail.vue | 6 +- .../org-src/installation/[id]/index.vue | 2 +- .../(features)/org-src/unit/[id]/index.vue | 2 +- 5 files changed, 198 insertions(+), 6 deletions(-) create mode 100644 app/components/app/unit-position/entry-detail.vue diff --git a/app/components/app/unit-position/entry-detail.vue b/app/components/app/unit-position/entry-detail.vue new file mode 100644 index 00000000..fb84e41a --- /dev/null +++ b/app/components/app/unit-position/entry-detail.vue @@ -0,0 +1,192 @@ + + + diff --git a/app/components/content/installation/detail.vue b/app/components/content/installation/detail.vue index c9337b5b..0f12ad8c 100644 --- a/app/components/content/installation/detail.vue +++ b/app/components/content/installation/detail.vue @@ -47,7 +47,7 @@ const title = ref('') // #region Props & Emits const props = defineProps<{ - installationId: string + installationId: number }>() const installation = ref({} as Installation) // #endregion diff --git a/app/components/content/unit/detail.vue b/app/components/content/unit/detail.vue index 1310621e..6c51624f 100644 --- a/app/components/content/unit/detail.vue +++ b/app/components/content/unit/detail.vue @@ -47,7 +47,7 @@ const title = ref('') // #region Props & Emits const props = defineProps<{ - unitId: string + unitId: number }>() const unit = ref({} as Unit) // #endregion @@ -86,7 +86,7 @@ const dataMap = computed(() => { }) const headerPrep: HeaderPrep = { - title: 'Detail Instalasi', + title: 'Detail Unit', icon: 'i-lucide-user', refSearchNav: { placeholder: 'Cari (min. 3 karakter)...', @@ -191,7 +191,7 @@ watch([recId, recAction], () => { } " > -