diff --git a/frontend/src/views/desktop/ManagerWorkspace.vue b/frontend/src/views/desktop/ManagerWorkspace.vue index 4ec9b3f..5189b14 100644 --- a/frontend/src/views/desktop/ManagerWorkspace.vue +++ b/frontend/src/views/desktop/ManagerWorkspace.vue @@ -14,8 +14,7 @@ const loading = ref(false) const allManagers = ref([]) // Date range filter -const dateFrom = ref('') -const dateTo = ref('') +const dateRange = ref(null) const searchText = ref('') const pageSize = ref(25) @@ -30,7 +29,10 @@ const page = ref>({ visits: 1, notes: 1, plans: 1, mini: const total = ref>({ visits: 0, notes: 0, plans: 0, mini: 0, key: 0 }) function getDateRange() { - return { from: dateFrom.value, to: dateTo.value } + if (dateRange.value && Array.isArray(dateRange.value) && dateRange.value.length === 2) { + return { from: dateRange.value[0], to: dateRange.value[1] } + } + return { from: '', to: '' } } const customers = ref([]) const allUsers = ref([]) @@ -344,20 +346,17 @@ const notesByDate = computed(() => {