diff --git a/src/views/tasks/CreateTask.vue b/src/views/tasks/CreateTask.vue index 2edf99f1..9cf0e296 100644 --- a/src/views/tasks/CreateTask.vue +++ b/src/views/tasks/CreateTask.vue @@ -12,7 +12,10 @@ v-model="newTask.title" v-focus /> - +

+ {{ errorMessage }} +

+ { : t('task.new') }) +const errorMessage = ref('') const descriptionFormVisible = ref(false) const newTask = ref(new TaskModel({})) const taskService = ref(new TaskService()) @@ -70,6 +74,12 @@ const taskService = ref(new TaskService()) const parsedTask = computed(() => parseTaskText(newTask.value.title, getQuickAddMagicMode())) async function create() { + if (newTask.value.title === '') { + errorMessage.value = t('list.create.addTitleRequired') + return + } + errorMessage.value = '' + newTask.value.listId = props.listId newTask.value.title = parsedTask.value.text const assignees = await findAssignees(parsedTask.value.assignees)