1
0

feat: port tasks store to pinia

This commit is contained in:
Dominik Pschenitschni
2022-09-23 12:55:53 +02:00
parent 1fdda07f65
commit 34ffd1d572
20 changed files with 157 additions and 128 deletions

View File

@ -73,6 +73,7 @@ import {PREFIXES} from '@/modules/parseTaskText'
import {useListStore} from '@/stores/lists'
import {useNamespaceStore} from '@/stores/namespaces'
import {useLabelStore} from '@/stores/labels'
import {useTaskStore} from '@/stores/tasks'
const TYPE_LIST = 'list'
const TYPE_TASK = 'task'
@ -412,7 +413,8 @@ export default defineComponent({
return
}
const task = await this.$store.dispatch('tasks/createNewTask', {
const taskStore = useTaskStore()
const task = await taskStore.createNewTask({
title: this.query,
listId: this.currentList.id,
})