1
0

feat: use async / await where it makes sense

This commit is contained in:
Dominik Pschenitschni
2021-10-11 19:37:20 +02:00
parent a776e1d2f3
commit bb94c1ba3a
74 changed files with 1458 additions and 1662 deletions

View File

@ -38,7 +38,7 @@ export default {
'$route.path': 'loadTasksOnSavedFilter',
},
methods: {
loadTasks(
async loadTasks(
page,
search = '',
params = null,
@ -76,14 +76,9 @@ export default {
}
this.tasks = []
this.taskCollectionService.getAll(list, params, page)
.then(r => {
this.tasks = r
this.currentPage = page
this.loadedList = JSON.parse(JSON.stringify(currentList))
})
this.tasks = await this.taskCollectionService.getAll(list, params, page)
this.currentPage = page
this.loadedList = JSON.parse(JSON.stringify(currentList))
},
loadTasksForPage(e) {