From 22bcbe3dda67bb8c4dbd632a8ac8925f6b0d9b5e Mon Sep 17 00:00:00 2001 From: Parker Berberian Date: Tue, 15 Jan 2019 12:49:20 -0500 Subject: Allow for Hosts to be Re-Imaged This change adds a button the user can press on thier booking detail page to reset thier host. They can choose to deploy any available image to thier servers (not just the one already used) Change-Id: I97a9869d2b38389c54f13173bb28a68cc52bb8d5 Signed-off-by: Parker Berberian --- dashboard/src/account/views.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'dashboard/src/account/views.py') diff --git a/dashboard/src/account/views.py b/dashboard/src/account/views.py index 09c5266..e880208 100644 --- a/dashboard/src/account/views.py +++ b/dashboard/src/account/views.py @@ -181,8 +181,8 @@ def account_booking_view(request): if not request.user.is_authenticated: return render(request, "dashboard/login.html", {'title': 'Authentication Required'}) template = "account/booking_list.html" - bookings = list(Booking.objects.filter(owner=request.user)) - collab_bookings = list(request.user.collaborators.all()) + bookings = list(Booking.objects.filter(owner=request.user).order_by("-start")) + collab_bookings = list(request.user.collaborators.all().order_by("-start")) context = {"title": "My Bookings", "bookings": bookings, "collab_bookings": collab_bookings} return render(request, template, context=context) -- cgit 1.2.3-korg