From 1212811391eaafb7e86a2fdc825b4b0ecc20df45 Mon Sep 17 00:00:00 2001 From: adityacp Date: Fri, 28 Feb 2020 11:46:41 +0530 Subject: Change in views, change password, paginator - Add bootstrap form control class in change password - Show alert messages in change password - Increase number of pages in paginator - Reduce number of course pages in moderator dashboard --- .../registration/password_change_form.html | 82 +++++++++++++++++++--- yaksh/templates/yaksh/paginator.html | 2 +- 2 files changed, 75 insertions(+), 9 deletions(-) (limited to 'yaksh/templates') diff --git a/yaksh/templates/registration/password_change_form.html b/yaksh/templates/registration/password_change_form.html index f286741..8d8424e 100644 --- a/yaksh/templates/registration/password_change_form.html +++ b/yaksh/templates/registration/password_change_form.html @@ -2,23 +2,89 @@ {% load static %} -{% block pagetitle %} - + +{% endblock %} +{% block pagetitle %} Change Password {% endblock %} {% block title %} Change Password {% endblock %} +{% block script %} + +{% endblock %} {% block content %}
{% csrf_token %}
- - {{ form }} -
+
+ + {% if form.errors %} + {% for field in form %} + {% for error in field.errors %} +
+ + {{ error|escape }} +
+ {% endfor %} + {% endfor %} + {% for error in qform.non_field_errors %} +
+ + {{ error|escape }} +
+ {% endfor %} + {% endif %} + {% for field in form %} + + + + + {% endfor %} +
{{ field.label }}{{ field }} {{ field.help_text }}
+

diff --git a/yaksh/templates/yaksh/paginator.html b/yaksh/templates/yaksh/paginator.html index 5438b77..5f0df7a 100644 --- a/yaksh/templates/yaksh/paginator.html +++ b/yaksh/templates/yaksh/paginator.html @@ -15,7 +15,7 @@
  • {{ n }}(current)
  • - {% elif n > objects.number|add:'-3' and n < objects.number|add:'3' %} + {% elif n > objects.number|add:'-5' and n < objects.number|add:'5' %}
  • {{ n }}
  • {% endif %} {% endfor %} -- cgit