From c055260bb88fd407c81ad0d40dd288a5aae4fb17 Mon Sep 17 00:00:00 2001 From: Mitch Riedstra Date: Tue, 7 Nov 2017 13:02:09 -0500 Subject: Updated middleware to force creation of user Identity. Fix issues with Identity creation. Added is_active to Django Admin UI for the dispatchAuth.models.User --- app/dispatch/templates/dispatch/identity/create.html | 8 ++++++++ app/dispatch/templates/dispatch/nav.html | 6 +++++- 2 files changed, 13 insertions(+), 1 deletion(-) (limited to 'app/dispatch/templates') diff --git a/app/dispatch/templates/dispatch/identity/create.html b/app/dispatch/templates/dispatch/identity/create.html index 90cdd8e..ab7b805 100644 --- a/app/dispatch/templates/dispatch/identity/create.html +++ b/app/dispatch/templates/dispatch/identity/create.html @@ -8,6 +8,14 @@ +
+
+

+ Your user account does not have a company identity. Please fill out the form to create one at this time. +

+
+
+
{% csrf_token %} {{ form.as_p }} diff --git a/app/dispatch/templates/dispatch/nav.html b/app/dispatch/templates/dispatch/nav.html index a5f09e5..ef65d24 100644 --- a/app/dispatch/templates/dispatch/nav.html +++ b/app/dispatch/templates/dispatch/nav.html @@ -1,4 +1,8 @@ -{% if request.user.is_authenticated %} +{% if False %} # Checking for user identity and limiting the nav if it doesn't exist {% endif %} + +{% if not request.user.identity %} +
  • Logout
  • +{% elif request.user.is_authenticated %}
  • Loads
  • Invoices
  • {% if request.user.is_superuser %} -- cgit v1.2.3