summaryrefslogtreecommitdiff
path: root/yaksh
diff options
context:
space:
mode:
Diffstat (limited to 'yaksh')
-rw-r--r--yaksh/templates/yaksh/addteacher.html3
-rw-r--r--yaksh/templates/yaksh/course_detail.html308
2 files changed, 124 insertions, 187 deletions
diff --git a/yaksh/templates/yaksh/addteacher.html b/yaksh/templates/yaksh/addteacher.html
index 755ba20..478da77 100644
--- a/yaksh/templates/yaksh/addteacher.html
+++ b/yaksh/templates/yaksh/addteacher.html
@@ -27,7 +27,7 @@
{% else %}
<center><b><u>Search Results</u></b></center><br>
<center><b>Search results does not include teachers already added</b></center><br>
- <table>
+ <table class="table table-striped">
<th></th>
<th>Username</th>
<th>First Name</th>
@@ -51,6 +51,7 @@
{% endif %}
{% endfor %}
</table>
+ </br>
<button class="btn" type="submit">Add Selected</button>
{% endif %}
{% endif %}
diff --git a/yaksh/templates/yaksh/course_detail.html b/yaksh/templates/yaksh/course_detail.html
index 5fb92f9..dc85080 100644
--- a/yaksh/templates/yaksh/course_detail.html
+++ b/yaksh/templates/yaksh/course_detail.html
@@ -9,200 +9,136 @@
{% endblock %}
{% block content %}
<br/>
-<div class="pull-right">
- <a class="btn btn-primary" href="{{URL_ROOT}}/exam/manage/toggle_status/{{ course.id }}/">{% if course.active %}Deactivate Course {% else %} Activate Course {% endif %}</a>
-</div>
-<br/>
+<br>
<div class="row">
- <div class="col-md-6">
- <center><b><u>Requests</u></b></center><br>
- {% if course.get_requests %}
- <input type="checkbox" class="checkall"/>&nbsp;<font size="2">Select all</font>
- <div id="enroll-all">
- <form action="{{URL_ROOT}}/exam/manage/enroll/{{ course.id }}/" method="post">
- {% csrf_token %}
- {% for request in course.get_requests %}
- <div class="well">
- <div class="row">
- <div class="col-md-3" style="padding-top:10px">
- <input type="checkbox" name="check" value="{{ request.id }}">&nbsp;
- <a href="#" data-toggle="modal" data-target="#request_detail_{{forloop.counter}}">
- {{ request.username }}</a>
- <div class="modal fade" id="request_detail_{{forloop.counter}}" role="dialog">
- <div class="modal-dialog">
- <div class="modal-content">
- <div class="modal-header">
- <button type="button" class="close" data-dismiss="modal">&times;</button>
- <h4 class="modal-title">Information for {{ request.username }} </h4>
- </div>
- <div class="modal-body">
- <table>
- <tr>
- <td><strong>Full Name :</strong></td>
- <td> {{request.get_full_name}}</td>
- </tr>
- <tr>
- <td><strong>Email ID :</strong></td>
- <td> {{request.email}}</td>
- </tr>
- <tr>
- <td><strong>Roll Number :</strong></td>
- <td> {{request.profile.roll_number}}</td>
- </tr>
- <tr>
- <td><strong>Institute :</strong></td>
- <td> {{request.profile.institute}}</td>
- </tr>
- <tr>
- <td><strong>Department :</strong></td>
- <td> {{request.profile.department}}</td>
- </tr>
- <tr>
- </table>
- </div>
- <div class="modal-footer">
- <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
- </div>
- </div>
+ <div class="col-sm-3 col-md-2 sidebar">
+ <ul class="nav nav-sidebar">
+ <li><a href="#student-requests" id="request"> Requested Students </a></li>
+ <li><a href="#enrolled-students" id="enroll-students"> Enrolled Students </a></li>
+ <li><a href="#rejected-students" id="reject-students"> Rejected Students </a></li>
+ <li>
+ <a href="{{URL_ROOT}}/exam/manage/toggle_status/{{ course.id }}/">
+ {% if course.active %}Deactivate Course {% else %} Activate Course {% endif %}</a>
+ </li>
+ </ul>
</div>
- </div>
- </div>
- <a class="btn btn-success" href="{{URL_ROOT}}/exam/manage/enroll/{{ course.id }}/{{ request.id }}/"> Enroll </a> <a class="btn btn-danger" href="{{URL_ROOT}}/exam/manage/reject/{{ course.id }}/{{ request.id }}/"> Reject </a>
+</div>
+<div class="col-md-9 col-md-offset-2 main">
+ <div class="row">
+ <div id="student-requests">
+ <center><b><u>Requests</u></b></center><br>
+ {% if course.get_requests %}
+ <input type="checkbox" class="checkall"/>&nbsp;<font size="2">Select all</font>
+ <div id="enroll-all">
+ <table class="table table-striped">
+ <th></th>
+ <th>Full Name</th>
+ <th>Email</th>
+ <th>Roll Number</th>
+ <th>Institute</th>
+ <th>Department</th>
+ <th>Enroll/Reject</th>
+ <form action="{{URL_ROOT}}/exam/manage/enroll/{{ course.id }}/" method="post">
+ {% csrf_token %}
+ {% for request in course.get_requests %}
+ <tr>
+ <td><input type="checkbox" name="check" value="{{ request.id }}"></td>
+ <td>{{request.get_full_name}}</td>
+ <td> {{request.email}}</td>
+ <td> {{request.profile.roll_number}}</td>
+ <td> {{request.profile.institute}}</td>
+ <td> {{request.profile.department}}</td>
+ <td>
+ <a class="btn btn-success"
+ href="{{URL_ROOT}}/exam/manage/enroll/{{ course.id }}/{{ request.id }}/">
+ Enroll </a>
+ <a class="btn btn-danger"
+ href="{{URL_ROOT}}/exam/manage/reject/{{ course.id }}/{{ request.id }}/">
+ Reject </a>
+ </td>
+ </tr>
+ {% endfor %}
+ </table>
+ <button class="btn btn-success" type="submit" name='enroll' value='enroll'>Enroll Selected</button>
</div>
+ {% endif %}
+ </form>
</div>
- {% endfor %}
- <button class="btn success" type="submit" name='enroll' value='enroll'>Enroll Selected</button>
- </div>
- {% endif %}
- </form>
- </div>
- <div class="col-md-6">
- <center><b><u>Rejected</u></b></center><br>
- {% if course.get_rejected %}
- <input type="checkbox" class="enroll"/>&nbsp;<font size="2">Select all</font>
- <div id="enroll">
- {% for rejected in course.get_rejected %}
- <form action="{{URL_ROOT}}/exam/manage/enroll/rejected/{{ course.id }}/" method="post">
- {% csrf_token %}
- <div class="well">
- <div class="row">
- <div class="col-md-4" style="padding-top:10px">
- <input type="checkbox" name="check" value="{{ rejected.id }}">&nbsp;
- <a href="#" data-toggle="modal" data-target="#reject_detail_{{forloop.counter}}">
- {{ rejected.username }}</a>
- <div class="modal fade" id="reject_detail_{{forloop.counter}}" role="dialog">
- <div class="modal-dialog">
- <div class="modal-content">
- <div class="modal-header">
- <button type="button" class="close" data-dismiss="modal">&times;</button>
- <h4 class="modal-title">Information for {{ rejected.username }} </h4>
- </div>
- <div class="modal-body">
- <table>
- <tr>
- <td><strong>Full Name :</strong></td>
- <td> {{rejected.get_full_name}}</td>
- </tr>
- <tr>
- <td><strong>Email ID :</strong></td>
- <td> {{rejected.email}}</td>
- </tr>
- <tr>
- <td><strong>Roll Number :</strong></td>
- <td> {{rejected.profile.roll_number}}</td>
- </tr>
- <tr>
- <td><strong>Institute :</strong></td>
- <td> {{rejected.profile.institute}}</td>
- </tr>
- <tr>
- <td><strong>Department :</strong></td>
- <td> {{rejected.profile.department}}</td>
- </tr>
- <tr>
- </table>
- </div>
- <div class="modal-footer">
- <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
- </div>
- </div>
- </div>
- </div>
- </div>
- <a class="btn btn-success" href="{{URL_ROOT}}/exam/manage/enroll/rejected/{{ course.id }}/{{ rejected.id }}/"> Enroll </a>
+ <br>
+ <div id="enrolled-students">
+ <center><b><u>Enrolled</u></b></center><br>
+ {% if course.get_enrolled %}
+ <input type="checkbox" class="reject"/>&nbsp;<font size="2">Select all</font>
+ <div id="reject">
+ <table class="table table-striped">
+ <th></th>
+ <th>Full Name</th>
+ <th>Email</th>
+ <th>Roll Number</th>
+ <th>Institute</th>
+ <th>Department</th>
+ <th>Reject</th>
+ {% for enrolled in course.get_enrolled %}
+ <form action="{{URL_ROOT}}/exam/manage/enrolled/reject/{{ course.id }}/" method="post">
+ {% csrf_token %}
+ <tr>
+ <td><input type="checkbox" name="check" value="{{ enrolled.id }}"></td>
+ <td> {{ enrolled.get_full_name|title }} </td>
+ <td> {{enrolled.email}}</td>
+ <td> {{enrolled.profile.roll_number}}</td>
+ <td> {{enrolled.profile.institute}}</td>
+ <td> {{enrolled.profile.department}}</td>
+ <td><a class="btn btn-danger"
+ href="{{URL_ROOT}}/exam/manage/enrolled/reject/{{ course.id }}/{{ enrolled.id }}/">
+ Reject </a>
+ </td>
+ </tr>
+ {% endfor %}
+ </table>
+ <button class="btn btn-danger" type="submit" name='reject' value='reject'>Reject Selected</button>
</div>
+ {% endif %}
+ </form>
</div>
- {% endfor %}
- <button class="btn btn-success" type="submit" name='enroll' value='enroll'>Enroll Selected</button>
- </div>
- {% endif %}
- </form>
- </div>
-</div>
-<br>
-<div class="row">
- <div class="col-md-6">
- <center><b><u>Enrolled</u></b></center><br>
- {% if course.get_enrolled %}
- <input type="checkbox" class="reject"/>&nbsp;<font size="2">Select all</font>
- <div id="reject">
- {% for enrolled in course.get_enrolled %}
- <form action="{{URL_ROOT}}/exam/manage/enrolled/reject/{{ course.id }}/" method="post">
- {% csrf_token %}
- <div class="well">
- <div class="row">
- <div class="col-md-4" style="padding-top:10px">
- <input type="checkbox" name="check" value="{{ enrolled.id }}">&nbsp;
- <a href="#" data-toggle="modal" data-target="#enroll_detail_{{forloop.counter}}">
- {{ enrolled.username }}</a>
- <div class="modal fade" id="enroll_detail_{{forloop.counter}}" role="dialog">
- <div class="modal-dialog">
- <div class="modal-content">
- <div class="modal-header">
- <button type="button" class="close" data-dismiss="modal">&times;</button>
- <h4 class="modal-title">Information for {{ enrolled.username }} </h4>
- </div>
- <div class="modal-body">
- <table>
- <tr>
- <td><strong>Full Name :</strong></td>
- <td> {{enrolled.get_full_name}}</td>
- </tr>
- <tr>
- <td><strong>Email ID :</strong></td>
- <td> {{enrolled.email}}</td>
- </tr>
- <tr>
- <td><strong>Roll Number :</strong></td>
- <td> {{enrolled.profile.roll_number}}</td>
- </tr>
- <tr>
- <td><strong>Institute :</strong></td>
- <td> {{enrolled.profile.institute}}</td>
- </tr>
- <tr>
- <td><strong>Department :</strong></td>
- <td> {{enrolled.profile.department}}</td>
- </tr>
- <tr>
- </table>
- </div>
- <div class="modal-footer">
- <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
- </div>
- </div>
- </div>
- </div>
- </div>
- <a class="btn btn-danger" href="{{URL_ROOT}}/exam/manage/enrolled/reject/{{ course.id }}/{{ enrolled.id }}/"> Reject </a>
+ <br>
+ <div id="rejected-students">
+ <center><b><u>Rejected</u></b></center><br>
+ {% if course.get_rejected %}
+ <input type="checkbox" class="enroll"/>&nbsp;<font size="2">Select all</font>
+ <div id="enroll">
+ <table class="table table-striped">
+ <th></th>
+ <th>Full Name</th>
+ <th>Email</th>
+ <th>Roll Number</th>
+ <th>Institute</th>
+ <th>Department</th>
+ <th>Enroll</th>
+ {% for rejected in course.get_rejected %}
+ <form action="{{URL_ROOT}}/exam/manage/enroll/rejected/{{ course.id }}/" method="post">
+ {% csrf_token %}
+ <tr>
+ <td><input type="checkbox" name="check" value="{{ rejected.id }}"></td>
+ <td>{{rejected.get_full_name|title}}</td>
+ <td> {{rejected.email}}</td>
+ <td> {{rejected.profile.roll_number}}</td>
+ <td> {{rejected.profile.institute}}</td>
+ <td> {{rejected.profile.department}}</td>
+ <td>
+ <a class="btn btn-success"
+ href="{{URL_ROOT}}/exam/manage/enroll/rejected/{{ course.id }}/{{ rejected.id }}/">
+ Enroll </a>
+ </td>
+ </tr>
+ {% endfor %}
+ </table>
+ <br>
+ <button class="btn btn-success" type="submit" name='enroll' value='enroll'>
+ Enroll Selected</button>
</div>
+ {% endif %}
+ </form>
</div>
- {% endfor %}
- <button class="btn btn-danger" type="submit" name='reject' value='reject'>Reject Selected</button>
- </div>
- {% endif %}
- </form>
</div>
</div>
-
{% endblock %}