diff --git a/app/main/views/dashboard.py b/app/main/views/dashboard.py index 8013acb9d..22f702095 100644 --- a/app/main/views/dashboard.py +++ b/app/main/views/dashboard.py @@ -75,6 +75,7 @@ def service_dashboard(service_id): "created_at": job["created_at"], "processing_finished": job.get("processing_finished"), "processing_started": job.get("processing_started"), + "scheduled_for": job.get("scheduled_for"), "notification_count": job["notification_count"], "created_by": job["created_by"], "template_name": job["template_name"], @@ -87,7 +88,7 @@ def service_dashboard(service_id): "views/dashboard/dashboard.html", updates_url=url_for(".service_dashboard_updates", service_id=service_id), partials=get_dashboard_partials(service_id), - jobs=jobs, + jobs=sorted(jobs, key=lambda job: job["created_at"], reverse=True)[:5], service_data_retention_days=service_data_retention_days, sms_sent=sms_sent, sms_allowance_remaining=sms_allowance_remaining, diff --git a/app/templates/views/dashboard/dashboard.html b/app/templates/views/dashboard/dashboard.html index 04abe1afc..5e40d0319 100644 --- a/app/templates/views/dashboard/dashboard.html +++ b/app/templates/views/dashboard/dashboard.html @@ -113,7 +113,7 @@