feat: Add Admin Loket detail page for managing patient queues, patient actions, and various selection dialogs.
This commit is contained in:
@@ -573,10 +573,18 @@ const klinikRuangList = computed(() => {
|
||||
const targetLayanan = isLoketEksekutif ? "Eksekutif" : "Reguler";
|
||||
|
||||
// Filter rooms by service type to match Loket's service level
|
||||
const baseList = (ruangStore.ruangData || []).filter(
|
||||
let baseList = (ruangStore.ruangData || []).filter(
|
||||
(k) => k.jenisLayanan === targetLayanan,
|
||||
);
|
||||
|
||||
// ADDITIONAL FILTER: Only show clinics that this loket actually serves
|
||||
const allowedServices = currentLoket?.pelayanan || [];
|
||||
if (allowedServices.length > 0) {
|
||||
baseList = baseList.filter(k =>
|
||||
allowedServices.includes(k.kodeKlinik)
|
||||
);
|
||||
}
|
||||
|
||||
// Sort clinics alphabetically by namaKlinik
|
||||
const sortedClinics = [...baseList].sort((a, b) =>
|
||||
(a.namaKlinik || "").localeCompare(b.namaKlinik || ""),
|
||||
|
||||
Reference in New Issue
Block a user