Fix: Refactor surat kontrol

This commit is contained in:
hasyim_kai
2025-11-13 11:56:21 +07:00
parent a14c4a5d3c
commit f582090d18
17 changed files with 17 additions and 18 deletions

No files matched your search

@@ -36,11 +36,10 @@ async function fetchDpjp(specialistId: string, subspecialistId: string) {
doctors.value = await getDoctorLabelList({
serviceType: 1,
serviceDate: new Date().toISOString().substring(0, 10),
specialistCode: 0,
includes: 'employee-person',
// "unit-id": parseInt(unitId),
"specialist-id": String(specialistId),
"subspecialist-id": String(subspecialistId),
"specialist-code": String(specialistId),
"subspecialist-code": String(subspecialistId),
}, true)
}
@@ -53,7 +52,8 @@ const selectedSubSpecialistId = inject<Ref<string | null>>("selectedSubSpecialis
// }
watch([ selectedSpecialistId, selectedSubSpecialistId], () => {
if ( selectedSpecialistId.value && selectedSubSpecialistId.value) {
if (selectedSpecialistId.value && selectedSubSpecialistId.value) {
console.log(`Select Doctor`)
fetchDpjp( selectedSpecialistId.value, selectedSubSpecialistId.value)
}
})
@@ -54,7 +54,6 @@ watch([selectedUnitId], () => {
fetchSpecialists(selectedUnitId.value)
}
})
console.log(selectedUnitId.value)
</script>
<template>
@@ -37,7 +37,7 @@ async function fetchSubSpecialists(specialistId: string) {
serviceType: 1,
serviceDate: new Date().toISOString().substring(0, 10),
specialistCode: 0,
"specialist-id": String(specialistId),
"specialist-code": String(specialistId),
}, true)
}