summaryrefslogtreecommitdiff
path: root/yaksh/templates
diff options
context:
space:
mode:
authoradityacp2017-10-05 11:53:49 +0530
committeradityacp2017-10-05 11:55:01 +0530
commit019a428295a52a7d5f1862ba5d0bda10dcea55a1 (patch)
treeb00ccdfe0981b97c78349038f88667d3e1fe51ca /yaksh/templates
parente79193180be5508c191a3401b018ff93c77791e5 (diff)
downloadonline_test-019a428295a52a7d5f1862ba5d0bda10dcea55a1.tar.gz
online_test-019a428295a52a7d5f1862ba5d0bda10dcea55a1.tar.bz2
online_test-019a428295a52a7d5f1862ba5d0bda10dcea55a1.zip
Show logged in user info in all templates
Diffstat (limited to 'yaksh/templates')
-rw-r--r--yaksh/templates/base.html6
-rw-r--r--yaksh/templates/user.html5
-rw-r--r--yaksh/templates/yaksh/intro.html5
-rw-r--r--yaksh/templates/yaksh/moderator_dashboard.html5
-rw-r--r--yaksh/templates/yaksh/question.html6
5 files changed, 26 insertions, 1 deletions
diff --git a/yaksh/templates/base.html b/yaksh/templates/base.html
index cbe396f..efac26d 100644
--- a/yaksh/templates/base.html
+++ b/yaksh/templates/base.html
@@ -52,7 +52,11 @@
{% block content %}
{% endblock %}
</div>
- <footer class="footer">
+ <footer class="footer" id="footer_div">
+ <div class="info" align="center">
+ {% block info %}
+ {% endblock %}
+ </div>
<div class="container">
<p align="center">Developed by FOSSEE group, IIT Bombay</p>
</div>
diff --git a/yaksh/templates/user.html b/yaksh/templates/user.html
index b068fae..83aea13 100644
--- a/yaksh/templates/user.html
+++ b/yaksh/templates/user.html
@@ -40,3 +40,8 @@
</div>
</div>
{% endblock %}
+{% if user %}
+ {% block info %}
+ <h5>{{user.get_full_name|title}}({{user.profile.roll_number}}) Logged in as {{user.username}}</h5>
+ {% endblock %}
+{% endif %}
diff --git a/yaksh/templates/yaksh/intro.html b/yaksh/templates/yaksh/intro.html
index 29723fa..3b9ba82 100644
--- a/yaksh/templates/yaksh/intro.html
+++ b/yaksh/templates/yaksh/intro.html
@@ -43,3 +43,8 @@
</div>
</div>
{% endblock content %}
+{% if user %}
+ {% block info %}
+ <h5>{{user.get_full_name|title}}({{user.profile.roll_number}}) Logged in as {{user.username}}</h5>
+ {% endblock %}
+{% endif %} \ No newline at end of file
diff --git a/yaksh/templates/yaksh/moderator_dashboard.html b/yaksh/templates/yaksh/moderator_dashboard.html
index c61675d..25bd580 100644
--- a/yaksh/templates/yaksh/moderator_dashboard.html
+++ b/yaksh/templates/yaksh/moderator_dashboard.html
@@ -79,3 +79,8 @@
</div>
{% endif %}
{% endblock %}
+{% if user %}
+ {% block info %}
+ <h5>{{user.get_full_name|title}}({{user.profile.roll_number}}) Logged in as {{user.username}}</h5>
+ {% endblock %}
+{% endif %}
diff --git a/yaksh/templates/yaksh/question.html b/yaksh/templates/yaksh/question.html
index eb6eb3d..bc7acf1 100644
--- a/yaksh/templates/yaksh/question.html
+++ b/yaksh/templates/yaksh/question.html
@@ -88,6 +88,7 @@ function call_skip(url)
}
init_val = '{{ last_attempt|escape_quotes|safe }}';
lang = "{{ question.language }}"
+
</script>
{% endblock script %}
@@ -250,3 +251,8 @@ lang = "{{ question.language }}"
</div>
</div>
{% endblock main %}
+{% if user %}
+ {% block info %}
+ <h5>{{user.get_full_name|title}}({{user.profile.roll_number}}) Logged in as {{user.username}}</h5>
+ {% endblock %}
+{% endif %}