add empty state for members activity, fix organization switch data loading problem

This commit is contained in:
Gregor Vostrak
2024-04-19 02:33:18 +02:00
parent 5d95dd4fae
commit 1cba8c39de
5 changed files with 41 additions and 15 deletions

View File

@@ -19,14 +19,8 @@ import NavigationSidebarItem from '@/Components/NavigationSidebarItem.vue';
import UserSettingsIcon from '@/Components/UserSettingsIcon.vue';
import MainContainer from '@/Pages/MainContainer.vue';
import { onMounted, ref } from 'vue';
import { useProjectsStore } from '@/utils/useProjects';
import { useTagsStore } from '@/utils/useTags';
import { useTasksStore } from '@/utils/useTasks';
import { useCurrentTimeEntryStore } from '@/utils/useCurrentTimeEntry';
import { useClientsStore } from '@/utils/useClients';
import { useMembersStore } from '@/utils/useMembers';
import NotificationContainer from '@/Components/NotificationContainer.vue';
import { useTimeEntriesStore } from '@/utils/useTimeEntries';
import { initializeStores } from '@/utils/init';
defineProps({
title: String,
@@ -38,13 +32,7 @@ onMounted(async () => {
// make sure that the initial requests are only loaded once, this can be removed once we move away from inertia
if (window.initialDataLoaded !== true) {
window.initialDataLoaded = true;
useProjectsStore().fetchProjects();
useTasksStore().fetchTasks();
useTagsStore().fetchTags();
useCurrentTimeEntryStore().fetchCurrentTimeEntry();
useClientsStore().fetchClients();
useMembersStore().fetchMembers();
useTimeEntriesStore().fetchTimeEntries();
initializeStores();
}
});
</script>