fix: loading list views would sometimes not get loaded
continuous-integration/drone/push Build is passing Details

To make sure the tasks of a list are only loaded after the list itself is fetched from the server, we hide the list view until the list is fully loaded. When switching between different views of the same list, this would cause the list view to not be loaded at all because the list was already loaded at that point.

closes #1732
This commit is contained in:
kolaente 2022-04-02 12:47:13 +02:00
parent 4bf016f53e
commit 2e537f6d63
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
1 changed files with 2 additions and 1 deletions

View File

@ -134,12 +134,13 @@ async function loadList(listIdToLoad: number) {
)
&& typeof currentList.value !== 'undefined' && currentList.value.maxRight !== null
) {
loadedListId.value = props.listId
return
}
console.debug(`Loading list, props.viewName = ${props.viewName}, $route.params =`, route.params, `, loadedListId = ${loadedListId.value}, currentList = `, currentList.value)
// Put set the current list to the one we're about to load so that the title is already shown at the top
// Set the current list to the one we're about to load so that the title is already shown at the top
loadedListId.value = 0
const listFromStore = store.getters['lists/getListById'](listData.id)
if (listFromStore !== null) {