diff --git a/src/views/dashboards/departmentDashboard/modules/daily-report/displays/DepartmentDashboardDailyReportNavigation.vue b/src/views/dashboards/departmentDashboard/modules/daily-report/displays/DepartmentDashboardDailyReportNavigation.vue index 694bef4b..e3761a19 100644 --- a/src/views/dashboards/departmentDashboard/modules/daily-report/displays/DepartmentDashboardDailyReportNavigation.vue +++ b/src/views/dashboards/departmentDashboard/modules/daily-report/displays/DepartmentDashboardDailyReportNavigation.vue @@ -4,6 +4,7 @@ import { selected_date, selected_date_to, selectDate, selected_department_ids, s import DatePeriodSelector from "@/components/displays/buttons/DatePeriodSelector.vue"; import { SessionUser } from "@/components/session/token/SessionUser.vue"; import { getDepartmentName } from "@/components/session/token/SessionUser/Objects/Departments.vue"; +import {BButton, BSkeleton} from "buefy"; /** * Props: @@ -18,9 +19,10 @@ const props = defineProps({ const accessibleDepartmentIds = ref([]); const departmentOptions = ref([]); const localSelectedIds = ref([]); - +const loadingDepartments = ref(false); const loadDepartments = async () => { // Get IDs user can access + loadingDepartments.value = true; accessibleDepartmentIds.value = SessionUser.functions.getAccessibleDepartments() || []; // Map to options with names const opts = []; @@ -40,6 +42,7 @@ const loadDepartments = async () => { localSelectedIds.value = [...accessibleDepartmentIds.value]; selectDepartments([...accessibleDepartmentIds.value]); } + loadingDepartments.value = false; }; onMounted(async () => { @@ -91,6 +94,7 @@ const toggleSelection = (id) => {