From eccf224a40e3fabb9a3c137e6375d93b3e1da2f4 Mon Sep 17 00:00:00 2001 From: philipp Date: Tue, 6 Jun 2023 10:08:54 +0200 Subject: [PATCH] order names by last access --- src/model/planned_event.rs | 1 - src/model/user.rs | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/model/planned_event.rs b/src/model/planned_event.rs index 490417a..9f3f542 100644 --- a/src/model/planned_event.rs +++ b/src/model/planned_event.rs @@ -224,7 +224,6 @@ FROM user_trip WHERE trip_details_id = (SELECT trip_details_id FROM planned_even event.planned_starting_time.replace(':', "") ))); vevent.push(Summary::new(event.name)); - vevent.push(Duration::new("PT3H")); calendar.add_event(vevent); } let mut buf = Vec::new(); diff --git a/src/model/user.rs b/src/model/user.rs index 166aeec..99e41e3 100644 --- a/src/model/user.rs +++ b/src/model/user.rs @@ -71,7 +71,7 @@ WHERE name like ? SELECT id, name, pw, is_cox, is_admin, is_guest, deleted, last_access FROM user WHERE deleted = 0 -ORDER BY name +ORDER BY last_access DESC " ) .fetch_all(db)