From 4f2c2dc8daeb5474fbfc4bd6071987b2797f5eba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C5=99emysl=20Eric=20Janouch?= Date: Thu, 26 Dec 2024 16:24:46 +0100 Subject: [PATCH] Order tasks by change date first The user presumably does not want to look everywhere for recent tasks. --- acid.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/acid.go b/acid.go index 350c9d8..cdf9007 100644 --- a/acid.go +++ b/acid.go @@ -244,7 +244,7 @@ var templateTasks = template.Must(template.New("tasks").Parse(` `)) func handleTasks(w http.ResponseWriter, r *http.Request) { - tasks, err := getTasks(r.Context(), `ORDER BY id DESC`) + tasks, err := getTasks(r.Context(), `ORDER BY changed DESC, id DESC`) if err != nil { http.Error(w, "Error retrieving tasks: "+err.Error(),