fix(quick add magic): create the task even when it only contains quick add magic keywords
Resolves https://github.com/go-vikunja/vikunja/issues/282
This commit is contained in:
parent
82ee9f18eb
commit
f1d9e4f25c
@ -408,7 +408,7 @@ export const useTaskStore = defineStore('task', () => {
|
||||
|
||||
return foundProjectId
|
||||
}
|
||||
|
||||
|
||||
async function createNewTask({
|
||||
title,
|
||||
bucketId,
|
||||
@ -420,6 +420,20 @@ export const useTaskStore = defineStore('task', () => {
|
||||
const cancel = setModuleLoading(setIsLoading)
|
||||
const quickAddMagicMode = authStore.settings.frontendSettings.quickAddMagicMode
|
||||
const parsedTask = parseTaskText(title, quickAddMagicMode)
|
||||
console.log(parsedTask)
|
||||
if(parsedTask.text === '') {
|
||||
const taskService = new TaskService()
|
||||
try {
|
||||
return taskService.create(new TaskModel({
|
||||
title,
|
||||
projectId,
|
||||
bucketId,
|
||||
position,
|
||||
}))
|
||||
} finally {
|
||||
cancel()
|
||||
}
|
||||
}
|
||||
|
||||
const foundProjectId = await findProjectId({
|
||||
project: parsedTask.project,
|
||||
|
Loading…
x
Reference in New Issue
Block a user