diff --git a/pages/category.html b/pages/category.html index 979aad7..d5d4633 100644 --- a/pages/category.html +++ b/pages/category.html @@ -111,9 +111,9 @@ {{ if not .Image }} - + {{ else }} - + {{ end }} {{ .Text }} {{ .TimeCreated }} @@ -240,15 +240,15 @@ async function drop(event) { return; } - // Add a copy of this ToDo in the corresponding group - let result = await postNewTodo({ + // Update todo's group ID + let result = await updateTodo(todoId, { text: draggedTodo.getElementsByClassName("todo-text")[0].innerText, groupId: Number(targetGroupId), dueUnix: Number(draggedTodo.getElementsByClassName("todo-due-unix")[0].innerText), + image: Array.from(draggedTodo.getElementsByClassName("todo-image")[0].src, char => char.charCodeAt(0)) }); - // Delete this ToDo in this group - await deleteTodoRefresh(todoId); + window.location.reload(); } document.addEventListener('DOMContentLoaded', async function() { diff --git a/pages/login.html b/pages/login.html index 2b0d35a..88c73f0 100644 --- a/pages/login.html +++ b/pages/login.html @@ -8,14 +8,14 @@

Log in

- Login + Email
@@ -42,21 +42,21 @@