diff --git a/Main/templates/form_base.html b/Main/templates/form_base.html index 112d630..d863003 100644 --- a/Main/templates/form_base.html +++ b/Main/templates/form_base.html @@ -15,16 +15,22 @@ {% block pageHeader %}{{ formName }}{% endblock %} +{% block belowHeader %}
{{ non_field_help_text }}
{% endblock %} + {% block mainContent %} {% load form_tags %}
- {% if not hide_back %} - - {% endif %} + {% if not hide_back %} + + {% endif %}
-
@@ -36,9 +42,9 @@ {% for field in form %}
{% if render_no_floating %} - - {{ field|setup_field:False }} + + {{ field|setup_field:False }} {% elif field in form.visible_fields %}
{{ field|setup_field:True }} @@ -49,11 +55,12 @@ {{ field|setup_field:"form-control" }} {% endif %} {% if field.help_text %} -
-
- {{ field.help_text }} -
+
+
+ {{ field.help_text }}
+
{% endif %} {% if field.errors %}
@@ -69,7 +76,9 @@
diff --git a/Users/views.py b/Users/views.py index 081a0a9..454ed45 100644 --- a/Users/views.py +++ b/Users/views.py @@ -57,6 +57,7 @@ class CompleteUserSetupView(LoginRequiredMixin, FormNameMixin, FormAlertMixin, U context = super(CompleteUserSetupView, self).get_context_data(**kwargs) context['render_no_floating'] = True + context['hide_back'] = self.object.email is None or self.object.email == "" return context def get(self, request, *args, **kwargs): @@ -88,7 +89,7 @@ class UserLoginView(FormAlertMixin, LoginView): def get_context_data(self, **kwargs) -> dict: """ This function defines additional context data to pass to the template - It hides the back button + It hides the back button and displays some help info :returns: Context data to pass to the template :rtype: dict @@ -96,6 +97,7 @@ class UserLoginView(FormAlertMixin, LoginView): context = super(UserLoginView, self).get_context_data(**kwargs) context['hide_back'] = True + context['non_field_help_text'] = "Use your Windows credentials to log in" return context def get_success_url(self) -> str: