From 5f5a6598c43f7df744c0a9127dced97103136cfe Mon Sep 17 00:00:00 2001 From: Matthew Lemon Date: Tue, 20 Oct 2020 12:13:58 +0100 Subject: added list of inspector names to home page --- ctrack/core/views.py | 3 +++ ctrack/templates/pages/home.html | 5 +++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/ctrack/core/views.py b/ctrack/core/views.py index 6482662..254fb86 100644 --- a/ctrack/core/views.py +++ b/ctrack/core/views.py @@ -1,3 +1,4 @@ +from django.contrib.auth import get_user_model from django.contrib.auth.decorators import login_required from django.shortcuts import render @@ -26,6 +27,7 @@ def home_page(request): }, ) else: + caf_users = get_user_model().objects.all() no_orgs = Organisation.objects.count() no_people = Person.objects.count() no_cafs = CAF.objects.count() @@ -37,5 +39,6 @@ def home_page(request): "no_cafs": no_cafs, "no_essential_services": no_essential_services, "no_systems": no_systems, + "caf_users": caf_users, } return render(request, "pages/home.html", context) diff --git a/ctrack/templates/pages/home.html b/ctrack/templates/pages/home.html index 1a5a64d..9ef16ac 100644 --- a/ctrack/templates/pages/home.html +++ b/ctrack/templates/pages/home.html @@ -91,8 +91,9 @@ Inspectors -- cgit v1.2.3