From 5a2001bcbc7cc4f24676d0a3df182871b7a8e987 Mon Sep 17 00:00:00 2001 From: Peter Clement Date: Tue, 25 Oct 2022 16:22:29 +0100 Subject: [PATCH] fix loading state --- .../components/portal/overview/backups/BackupsTab.svelte | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/packages/builder/src/components/portal/overview/backups/BackupsTab.svelte b/packages/builder/src/components/portal/overview/backups/BackupsTab.svelte index acc8573e31..0afb7c1760 100644 --- a/packages/builder/src/components/portal/overview/backups/BackupsTab.svelte +++ b/packages/builder/src/components/portal/overview/backups/BackupsTab.svelte @@ -37,7 +37,7 @@ let startDate = null let endDate = null let filters = getFilters() - + let loaded = false $: page = $pageInfo.page $: fetchBackups(filterOpt, page, startDate, endDate) @@ -161,7 +161,10 @@ onMount(() => { fetchBackups(filterOpt, page, startDate, endDate) + loaded = true }) + $: console.log(loaded) + $: console.log(backups.length)
@@ -207,7 +210,7 @@
- {:else if backupData?.length === 0 && !filterOpt && !startDate} + {:else if backupData?.length === 0 && !loaded && !filterOpt && !startDate}
- {:else} + {:else if loaded}