summaryrefslogtreecommitdiff
path: root/yaksh/templates
diff options
context:
space:
mode:
authoradityacp2020-01-03 11:17:04 +0530
committeradityacp2020-01-03 11:17:04 +0530
commit664fa46ba041ebdc5912a3bf125056bbc52b1f95 (patch)
tree67e9c64e62906e8ad63e0e6e9f1324ce69da0fe0 /yaksh/templates
parent293e95bd0920d2f06058cf3ee4c0be3c2b3cf905 (diff)
downloadonline_test-664fa46ba041ebdc5912a3bf125056bbc52b1f95.tar.gz
online_test-664fa46ba041ebdc5912a3bf125056bbc52b1f95.tar.bz2
online_test-664fa46ba041ebdc5912a3bf125056bbc52b1f95.zip
Remove unncessary break html tags and add bootstrap custom file input
Diffstat (limited to 'yaksh/templates')
-rw-r--r--yaksh/templates/registration/password_change_done.html7
-rw-r--r--yaksh/templates/registration/password_change_form.html11
-rw-r--r--yaksh/templates/registration/password_reset_complete.html1
-rw-r--r--yaksh/templates/registration/password_reset_done.html1
-rw-r--r--yaksh/templates/registration/password_reset_form.html1
-rw-r--r--yaksh/templates/yaksh/add_course.html6
-rw-r--r--yaksh/templates/yaksh/complete.html2
-rw-r--r--yaksh/templates/yaksh/courses.html1
-rw-r--r--yaksh/templates/yaksh/editprofile.html3
-rw-r--r--yaksh/templates/yaksh/login.html3
-rw-r--r--yaksh/templates/yaksh/moderator_dashboard.html7
-rw-r--r--yaksh/templates/yaksh/register.html3
-rw-r--r--yaksh/templates/yaksh/showquestions.html80
13 files changed, 69 insertions, 57 deletions
diff --git a/yaksh/templates/registration/password_change_done.html b/yaksh/templates/registration/password_change_done.html
index 9dd04b5..34045d4 100644
--- a/yaksh/templates/registration/password_change_done.html
+++ b/yaksh/templates/registration/password_change_done.html
@@ -1,5 +1,12 @@
{% extends "base.html" %}
{% load static %}
+{% block pagetitle %}
+<nav class="navbar navbar-expand-lg navbar-dark bg-primary fixed-top">
+ <a class="navbar-brand" href="{% url 'yaksh:index' %}">
+ <img src="{% static 'yaksh/images/yaksh_banner.png' %}" alt="YAKSH">
+ </a>
+</nav>
+{% endblock %}
{% block title %} Change Password {% endblock %}
{% block script %}
diff --git a/yaksh/templates/registration/password_change_form.html b/yaksh/templates/registration/password_change_form.html
index b4880c6..f286741 100644
--- a/yaksh/templates/registration/password_change_form.html
+++ b/yaksh/templates/registration/password_change_form.html
@@ -1,11 +1,18 @@
{% extends "base.html" %}
+{% load static %}
<!DOCTYPE html>
-{% block pagetitle %} Change Password {% endblock %}
+{% block pagetitle %}
+<nav class="navbar navbar-expand-lg navbar-dark bg-primary fixed-top">
+ <a class="navbar-brand" href="{% url 'yaksh:index' %}">
+ <img src="{% static 'yaksh/images/yaksh_banner.png' %}" alt="YAKSH">
+ </a>
+</nav>
+Change Password
+{% endblock %}
{% block title %} Change Password {% endblock %}
{% block content %}
-<br><br>
<form action="" method="post" >
{% csrf_token %}
<center>
diff --git a/yaksh/templates/registration/password_reset_complete.html b/yaksh/templates/registration/password_reset_complete.html
index 20dc697..ddf94a6 100644
--- a/yaksh/templates/registration/password_reset_complete.html
+++ b/yaksh/templates/registration/password_reset_complete.html
@@ -12,7 +12,6 @@
{% endblock %}
{% block content %}
-<br><br>
<center>
<div class="container">
<p>Your password has been reset. </p>
diff --git a/yaksh/templates/registration/password_reset_done.html b/yaksh/templates/registration/password_reset_done.html
index 036d691..94138dd 100644
--- a/yaksh/templates/registration/password_reset_done.html
+++ b/yaksh/templates/registration/password_reset_done.html
@@ -11,7 +11,6 @@
{% endblock %}
{% block content %}
-<br><br>
<center>
<h2>Password reset successful</h2>
<div class="alert alert-success col-md-8">
diff --git a/yaksh/templates/registration/password_reset_form.html b/yaksh/templates/registration/password_reset_form.html
index eeca8f2..acee288 100644
--- a/yaksh/templates/registration/password_reset_form.html
+++ b/yaksh/templates/registration/password_reset_form.html
@@ -12,7 +12,6 @@
{% endblock %}
{% block content %}
-<br><br>
<center>
<h4>Enter your registered email address to reset your password</h4>
<div class="container">
diff --git a/yaksh/templates/yaksh/add_course.html b/yaksh/templates/yaksh/add_course.html
index 2f584c9..6276425 100644
--- a/yaksh/templates/yaksh/add_course.html
+++ b/yaksh/templates/yaksh/add_course.html
@@ -1,8 +1,6 @@
{% extends "manage.html" %}
{% load static %}
-{% block title %}Add Course{% endblock %}
-
{% block css %}
<link rel="stylesheet" href="{% static 'yaksh/css/jquery.datetimepicker.css' %}">
{% endblock %}
@@ -11,9 +9,9 @@
<script type="text/javascript" src="{% static 'yaksh/js/jquery.datetimepicker.full.min.js' %}">
</script>
{% endblock %}
-
+{% block title %} Add Course {% endblock %}
+{% block pagetitle %} Add Course {% endblock %}
{% block content %}
-<br><br><br>
<div class="container">
<div class="row">
<div class="col-md-8">
diff --git a/yaksh/templates/yaksh/complete.html b/yaksh/templates/yaksh/complete.html
index 03dc4c1..8c8073e 100644
--- a/yaksh/templates/yaksh/complete.html
+++ b/yaksh/templates/yaksh/complete.html
@@ -49,7 +49,7 @@
</center>
{% endif %}
<br><br>
- <center class="container-fluid">
+ <center class="container">
<h5>
<span class="alert alert-success">{{message}}</span>
</h5>
diff --git a/yaksh/templates/yaksh/courses.html b/yaksh/templates/yaksh/courses.html
index 4548d33..e5f3936 100644
--- a/yaksh/templates/yaksh/courses.html
+++ b/yaksh/templates/yaksh/courses.html
@@ -11,7 +11,6 @@
</style>
{% endblock %}
{% block content %}
-<br><br>
<div class="container-fluid">
<div class="container">
<div class="row">
diff --git a/yaksh/templates/yaksh/editprofile.html b/yaksh/templates/yaksh/editprofile.html
index 2161716..47e74ea 100644
--- a/yaksh/templates/yaksh/editprofile.html
+++ b/yaksh/templates/yaksh/editprofile.html
@@ -1,9 +1,8 @@
{% extends template %}
{% block title %} Edit Profile {% endblock %}
+{% block pagetitle %} My Profile {% endblock %}
{% block main %}
-<br><br><br>
<div class="container">
- <center><h2> My Profile </h2></center>
<br>
<form action="{% url 'yaksh:edit_profile'%}" method="post" >
{% csrf_token %}
diff --git a/yaksh/templates/yaksh/login.html b/yaksh/templates/yaksh/login.html
index 464a8dd..e2adca7 100644
--- a/yaksh/templates/yaksh/login.html
+++ b/yaksh/templates/yaksh/login.html
@@ -4,7 +4,7 @@
{% block title %} Login {% endblock %}
{% block nav %}
-<nav class="navbar navbar-expand-lg navbar-dark bg-primary">
+<nav class="navbar navbar-expand-lg navbar-dark bg-primary fixed-top">
<a class="navbar-brand" href="{% url 'yaksh:index' %}">
<img src="{% static 'yaksh/images/yaksh_banner.png' %}" alt="YAKSH">
</a>
@@ -12,7 +12,6 @@
{% endblock %}
{% block content %}
-<center></center>
<div class="container">
<div class="row justify-content-center">
<div class="col-md-6 col-md-offset-6">
diff --git a/yaksh/templates/yaksh/moderator_dashboard.html b/yaksh/templates/yaksh/moderator_dashboard.html
index b36bc2d..db37983 100644
--- a/yaksh/templates/yaksh/moderator_dashboard.html
+++ b/yaksh/templates/yaksh/moderator_dashboard.html
@@ -1,13 +1,12 @@
{% extends "manage.html" %}
{% load custom_filters %}
-{% block title %} Moderartor Dashboard {% endblock %}
+{% block title %} My Dashboard {% endblock %}
+{% block pagetitle %} <h2>My Dashboard</h2> {% endblock %}
{% block content %}
-<br><br>
<div class="container">
<center>
- {% block pagetitle %} <h2>My Dashboard</h2> {% endblock %}
<h4>
List of quizzes! Click on the given links to have a look at answer papers for a quiz
</h4>
@@ -44,7 +43,7 @@
<div id="accordion">
{% for course in courses %}
<div class="card">
- <div class="card-header" style="height: 100px">
+ <div class="card-header">
<div class="row">
<div class="col-md-4">
<h4 data-toggle="tooltip" title="{{course.name}}">
diff --git a/yaksh/templates/yaksh/register.html b/yaksh/templates/yaksh/register.html
index 33bc561..454cd5b 100644
--- a/yaksh/templates/yaksh/register.html
+++ b/yaksh/templates/yaksh/register.html
@@ -2,6 +2,7 @@
{% load static %}
{% block title %} Register {% endblock %}
+{% block pagetitle %} Registration {% endblock %}
{% block nav %}
<nav class="navbar navbar-expand-lg navbar-dark bg-primary fixed-top">
@@ -13,8 +14,6 @@
{% block content %}
<div class="container-fluid">
- <br>
- {% block pagetitle %}<center><h1> Registration </h1></center>{% endblock %}
<div class="row justify-content-center form-group">
<div class="col-md-4 col-md-offset-4">
<form action="" method="post">
diff --git a/yaksh/templates/yaksh/showquestions.html b/yaksh/templates/yaksh/showquestions.html
index d0c33dd..c9a7690 100644
--- a/yaksh/templates/yaksh/showquestions.html
+++ b/yaksh/templates/yaksh/showquestions.html
@@ -46,20 +46,31 @@
</p>
</div>
<div class="card-body">
- <div><a class="btn btn-lg btn-primary" href="{% url 'yaksh:download_yaml_template' %}">Download Template</a></div>
- <br/>
- <h4> Or </h4>
<form action="" method="post" enctype="multipart/form-data">
{% csrf_token %}
- <div class="form-group">
- <div class="input-group mb-3">
- <div class="custom-file">
- {{ upload_form.as_p }}
+ <div class="form-group col-md-6">
+ <a class="btn btn-lg btn-primary" href="{% url 'yaksh:download_yaml_template' %}">Download Template</a>
+ <br><br>
+ <h4> Or </h4>
+ <br>
+ <div class="input-group mb-3">
+ <div class="custom-file">
+ {{ upload_form }}
+ <label class="custom-file-label" for="id_file">
+ Choose file
+ </label>
+ </div>
</div>
- </div>
+ <button class="btn btn-lg btn-success" type="submit" name="upload" value="upload">Upload File</button>
</div>
- <h4>And</h4>
- <button class="btn btn-lg btn-success" type="submit" name="upload" value="upload">Upload File</button>
+ <script>
+ $('#id_file').on('change',function(){
+ //get the file name
+ var fileName = $(this).val();
+ //replace the "Choose a file" label
+ $(this).next('.custom-file-label').html(fileName);
+ })
+ </script>
</form>
</div>
</div>
@@ -67,36 +78,32 @@
<!-- Show questions -->
<div id="show" class="tab-pane fade show active" role="tabpanel" aria-labelledby="showbar">
- <form name=frm action="" method="post">
- {% csrf_token %}
- {% if message %}
- {%if message == "Questions Uploaded Successfully"%}
- <div class="alert alert-success alert-dismissable">
- <a href="#" class="close" data-dismiss="alert" aria-label="close"><span class="fa fa-window-close"></span></a>
- {{ message }}
- </div>
- {%else %}
- <div class="alert alert-danger alert-dismissable">
- <a href="#" class="close" data-dismiss="alert" aria-label="close"><span class="fa fa-window-close"></span></a>
- {{ message }}
- </div>
- {% endif %}
- {% endif %}
- {% if msg %}
- <div class="alert alert-danger alert-dismissable animated flash">
- <a href="#" class="close" data-dismiss="alert" aria-label="close"><span class="fa fa-window-close"></span></a>
- {{ msg }}
- </div>
- {% endif %}
- </form>
- <form name=frm action="" method="post">
+ {% if messages %}
+ {% for message in messages %}
+ <div class="alert alert-dismissible alert-info">
+ <button type="button" class="close" data-dismiss="alert">
+ <i class="fa fa-close"></i>
+ </button>
+ <strong>{{ message }}</strong>
+ </div>
+ {% endfor %}
+ {% endif %}
+ <form name=frm action="" method="post">
<div class="card">
<div class="card-body">
<!-- Filtering Questions -->
<div id="selectors">
<h4>Filters Questions: </h4>
<div class="dropdown">
- {{ form.question_type }} {{ form.language }} {{ form.marks }}
+ <div class="col-md-4">
+ {{ form.question_type }}
+ </div>
+ <div class="col-md-4">
+ {{ form.language }}
+ </div>
+ <div class="col-md-4">
+ {{ form.marks }}
+ </div>
</div>
</div>
<hr>
@@ -174,6 +181,7 @@
{% include "yaksh/paginator.html" %}
{% endif %}
</div>
+ <br>
<center>
<a class="btn btn-lg btn-primary" href="{% url 'yaksh:add_question' %}">Add Question</a>
@@ -183,10 +191,10 @@
{% endif %}
<button class="btn btn-lg btn-danger" type="submit" onClick="return confirm_delete(frm);" name='delete' value='delete'>Delete Selected</button>
</center>
- </form>
+ </form>
</div>
<!-- End of Show questions -->
- </div>
+ </div>
</div>
{% endblock %}