summaryrefslogtreecommitdiff
path: root/yaksh/templates
diff options
context:
space:
mode:
authorprathamesh2018-01-02 22:09:44 +0530
committerprathamesh2018-01-02 22:09:44 +0530
commit44e16651a9f7faec95a32c19738a996a731ae57a (patch)
tree0aa8439547b0f1281ab78964aaf3f7ad176ed6da /yaksh/templates
parente14514e01052fb36cd9f14675cbe7ca940945a34 (diff)
parente566d54239efcb46f253e324b7295a676378f656 (diff)
downloadonline_test-44e16651a9f7faec95a32c19738a996a731ae57a.tar.gz
online_test-44e16651a9f7faec95a32c19738a996a731ae57a.tar.bz2
online_test-44e16651a9f7faec95a32c19738a996a731ae57a.zip
Merge branch 'master' of https://github.com/FOSSEE/online_test into exercise
Conflicts Resolved: yaksh/templates/yaksh/courses.html yaksh/templates/yaksh/question.html
Diffstat (limited to 'yaksh/templates')
-rw-r--r--yaksh/templates/base.html4
-rw-r--r--yaksh/templates/exam.html5
-rw-r--r--yaksh/templates/manage.html48
-rw-r--r--yaksh/templates/user.html21
-rw-r--r--yaksh/templates/yaksh/add_lesson.html15
-rw-r--r--yaksh/templates/yaksh/add_module.html48
-rw-r--r--yaksh/templates/yaksh/add_question.html2
-rw-r--r--yaksh/templates/yaksh/complete.html3
-rw-r--r--yaksh/templates/yaksh/course_detail.html4
-rw-r--r--yaksh/templates/yaksh/course_modules.html6
-rw-r--r--yaksh/templates/yaksh/courses.html61
-rw-r--r--yaksh/templates/yaksh/design_course_session.html41
-rw-r--r--yaksh/templates/yaksh/grade_user.html3
-rw-r--r--yaksh/templates/yaksh/intro.html2
-rw-r--r--yaksh/templates/yaksh/login.html6
-rw-r--r--yaksh/templates/yaksh/question.html11
-rw-r--r--yaksh/templates/yaksh/quit.html3
-rw-r--r--yaksh/templates/yaksh/show_video.html83
-rw-r--r--yaksh/templates/yaksh/user_data.html3
-rw-r--r--yaksh/templates/yaksh/view_answerpaper.html3
20 files changed, 250 insertions, 122 deletions
diff --git a/yaksh/templates/base.html b/yaksh/templates/base.html
index e7c4a99..08c4f70 100644
--- a/yaksh/templates/base.html
+++ b/yaksh/templates/base.html
@@ -53,8 +53,9 @@
{% endblock %}
</div>
</div>
+ <div class="container">
<footer class="footer" id="footer_div">
- <div class="logged_user_info" align="center">
+ <div class="logged_user_info" align="center" >
{% block info %}
{% endblock %}
</div>
@@ -62,6 +63,7 @@
<p align="center">Developed by FOSSEE group, IIT Bombay</p>
</div>
</footer>
+ </div>
</body>
</html>
diff --git a/yaksh/templates/exam.html b/yaksh/templates/exam.html
index 4fd83dd..ce1d3b8 100644
--- a/yaksh/templates/exam.html
+++ b/yaksh/templates/exam.html
@@ -12,7 +12,10 @@
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
- <a class="navbar-brand" href="#"> Yaksh </a>
+ <a class="navbar-brand" href="#">
+ <img src="{{ URL_ROOT }}/static/yaksh/images/yaksh_banner.png" alt="YAKSH" style="margin-top: -3px; margin-left:-15px">
+ </img>
+ </a>
</div>
<div class= "collapse navbar-collapse" id="navbar">
<form id="logout" action="{{URL_ROOT}}/exam/quit/{{ paper.attempt_number }}/{{module.id}}/{{ paper.question_paper.id }}/{{course.id}}/" method="post" class="pull-right">
diff --git a/yaksh/templates/manage.html b/yaksh/templates/manage.html
index d87076d..17ce23e 100644
--- a/yaksh/templates/manage.html
+++ b/yaksh/templates/manage.html
@@ -8,22 +8,56 @@
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
- <a class="navbar-brand" href="{{ URL_ROOT }}/exam/manage/"> Online Test </a>
+ <a class="navbar-brand navbar-left" href="{{ URL_ROOT }}/exam/manage/">
+ <img src="{{ URL_ROOT }}/static/yaksh/images/yaksh_banner.png" alt="YAKSH" style="margin-top: -3px; margin-left:-15px"></img>
+ </a>
</div>
<div id="navbar" class="collapse navbar-collapse">
- <ul class="nav navbar-nav">
+ <ul class="nav navbar-nav navbar-right">
<li><a href="{{ URL_ROOT }}/exam/manage/questions">Questions</a></li>
- <li><a href="{{ URL_ROOT }}/exam/manage/gradeuser">Grade User</a></li>
- <li><a href="{{ URL_ROOT }}/exam/manage/monitor">Monitor</a></li>
<li><a href="{{ URL_ROOT }}/exam/manage/courses">Courses</a></li>
- <li><a href="{{ URL_ROOT }}/exam/viewprofile">My Profile</a></li>
- <li><a href="{{ URL_ROOT }}/exam/reset/changepassword">Change Password</a></li>
+ <li><a href="{{ URL_ROOT }}/exam/manage/monitor">Monitor</a></li>
+ <li><a href="{{ URL_ROOT }}/exam/manage/gradeuser">Grade User</a></li>
<li><a href="{{ URL_ROOT }}/exam/manage/grader"> Grader </a></li>
- <li><a style='cursor:pointer' onClick='location.replace("{{URL_ROOT}}/exam/logout/");'>Log out</a></li>
+ <li><a href="{{ URL_ROOT }}/exam/reset/changepassword">Change Password</a></li>
+ <li><a href="{{ URL_ROOT }}/exam/viewprofile"> {{ user.get_full_name.title }} </a></li>
+ <li><a href="{{URL_ROOT}}/exam/logout/" id="logout">Logout</a></li>
</ul>
</div><!-- /.navbar -->
</div><!-- /.container -->
</nav><!-- /.navbar -->
+
+ <!-- iframe div for video embed -->
+ <div id="iframe_div" style="display: none;">
+ <div style="width: 640px; height: 480px; position: relative;">
+ <iframe id="video_frame" width="800" height="500" frameborder="0" allowfullscreen>
+ </iframe>
+ <div style="width: 80px; height: 80px; position: absolute; opacity: 0; right: 0px; top: 0px;">&nbsp;
+ </div>
+ </div>
+ </div>
+ <!-- end iframe div -->
+
+ <!-- Dialog to video embed -->
+ <div id="dialog_iframe" title="Embed Video URL" style="display: none;">
+ <label>Enter Url:</label>
+ <input id="url" name="url" type="text" required="true">
+ <input type="button" id="submit_info" name="submit_info" class="btn" value="Submit" />
+ <div id="error_div" style="display: none;">
+ <b> Please enter URL</b>
+ </div>
+ <div id="copy_div">
+ <br>
+ <label>Paste HTML to embed in website:</label>
+ <textarea rows="5" cols="35" id="html_text"></textarea>
+ <br>
+ <a class="btn btn-default" id="copy" data-toggle="tooltip" title="Copy to Clipboard">
+ <i class="fa fa-clipboard" aria-hidden="true"></i>
+ </a>
+ </div>
+ </div>
+ <!-- end dialog -->
+
{% endblock %}
{% block content %}
{% block main %}
diff --git a/yaksh/templates/user.html b/yaksh/templates/user.html
index a50451e..090e93d 100644
--- a/yaksh/templates/user.html
+++ b/yaksh/templates/user.html
@@ -11,12 +11,17 @@
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
- <a class="navbar-brand" href="{{ URL_ROOT }}/exam/quizzes"> Yaksh </a>
+ <a class="navbar-brand navbar-left" href="{{ URL_ROOT }}/exam/">
+ <img src="{{ URL_ROOT }}/static/yaksh/images/yaksh_banner.png" alt="YAKSH" style="margin-top: -3px; margin-left:-15px">
+ </img>
+ </a>
</div>
<div class= "collapse navbar-collapse" id="navbar">
<ul class="nav navbar-nav navbar-right">
+ <li><a href="{{ URL_ROOT }}/exam/quizzes/enrolled/"> Enrolled Courses </a></li>
+ <li><a href="{{ URL_ROOT }}/exam/reset/changepassword"> Change Password </a></li>
<li><a href="{{ URL_ROOT }}/exam/viewprofile"> {{ user.get_full_name.title }} </a></li>
- <li><a style='cursor:pointer' id='logout' onClick='location.replace("{{URL_ROOT}}/exam/logout/");'> <span class="glyphicon glyphicon-log-out">Logout </span></a></li>
+ <li><a href="{{URL_ROOT}}/exam/logout/" id="logout">Logout</a></li>
</ul>
</div><!-- /.navbar -->
</div><!-- /.container -->
@@ -24,16 +29,6 @@
{% endblock %}
{% block content %}
<div class="row">
- <div class="col-sm-3 col-md-2 sidebar">
- <ul class="nav nav-sidebar">
- <li><a href="{{ URL_ROOT }}/exam/quizzes"> Home </a></li>
- <li><a href="{{ URL_ROOT }}/exam/quizzes/enrolled/"> Enrolled Courses </a></li>
- <li><a href="{{ URL_ROOT }}/exam/viewprofile"> Profile </a></li>
- <li><a href="{{ URL_ROOT }}/exam/reset/changepassword"> Change Password </a></li>
- </ul>
- {% block usersidebar %}
- {% endblock %}
- </div>
<div class="col-sm-8 col-sm-offset-3 col-md-9 col-md-offset-2 main">
<div class="row">
{% block main %}
@@ -44,6 +39,6 @@
{% endblock %}
{% if user %}
{% block info %}
- <h5>{{user.get_full_name|title}}({{user.profile.roll_number}}) Logged in as {{user.username}}</h5>
+ <h5><b>{{user.get_full_name|title}}</b> with Roll no. <b>{{user.profile.roll_number}}</b> is logged in as <b>{{user.username}}</b></h5>
{% endblock %}
{% endif %}
diff --git a/yaksh/templates/yaksh/add_lesson.html b/yaksh/templates/yaksh/add_lesson.html
index 9e1ee1d..d9bc1e7 100644
--- a/yaksh/templates/yaksh/add_lesson.html
+++ b/yaksh/templates/yaksh/add_lesson.html
@@ -5,6 +5,11 @@
{% block script %}
<script src="{{ URL_ROOT }}/static/yaksh/js/lesson.js"></script>
+<script src="https://code.jquery.com/ui/1.9.1/jquery-ui.js"></script>
+{% endblock %}
+
+{% block css %}
+<link rel="stylesheet" href="https://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">
{% endblock %}
{% block content %}
@@ -43,9 +48,17 @@
<button class="btn" type="submit" id="submit" name="Delete"> Delete Files
</button>
{% endif %}
+ {% if course_id %}
<button class="btn" type="button" name="button" onClick='location.replace("{{URL_ROOT}}/exam/manage/courses/");'>Cancel</button>
+ {% else %}
+ <button class="btn" type="button" name="button" onClick='location.replace("{{URL_ROOT}}/exam/manage/courses/all_lessons/");'>Cancel</button>
+ {% endif %}
+ </form>
<button class="btn" type="button" name="button" id="preview">Preview Lesson Description
</button>
+ <button class="btn" type="button" name="button" id="embed">
+ Embed Video link
+ </button>
</center>
<hr>
<div class="panel panel-default" id="preview_text_div" style="display: none;">
@@ -57,5 +70,5 @@
<div class="panel-body" id="description_body">
</div>
</div>
-</form>
+
{% endblock %} \ No newline at end of file
diff --git a/yaksh/templates/yaksh/add_module.html b/yaksh/templates/yaksh/add_module.html
index 07fcb5f..4efccf7 100644
--- a/yaksh/templates/yaksh/add_module.html
+++ b/yaksh/templates/yaksh/add_module.html
@@ -1,5 +1,4 @@
{% extends "manage.html" %}
-{% load custom_filters %}
{% block title %}Create/Edit Learning Module{% endblock %}
{% block pagetitle %}<h4>Design Learning Module</h4>{% endblock %}
@@ -8,10 +7,12 @@
<script src="{{ URL_ROOT }}/static/yaksh/js/jquery-1.9.1.min.js"></script>
<script src="{{ URL_ROOT }}/static/yaksh/js/design_course.js"></script>
<script src="{{ URL_ROOT }}/static/yaksh/js/lesson.js"></script>
+<script src="{{ URL_ROOT }}/static/yaksh/js/jquery-ui.js"></script>
{% endblock %}
{% block css %}
<link rel="stylesheet" media="all" type="text/css" href="{{ URL_ROOT }}/static/yaksh/css/design_course.css" />
+<link rel="stylesheet" href="{{ URL_ROOT }}/static/yaksh/css/jquery-ui/jquery-ui.css">
{% endblock %}
{% block content %}
@@ -33,11 +34,15 @@
</center>
<br><br>
<center>
- <button class="btn" type="submit" id="submit" name="Save"> Save
+ <button class="btn" type="submit" id="submit" name="Save">
+ Save
</button>
<button class="btn" type="button" name="button" id="preview">
Preview Module Description
</button>
+ <button class="btn" type="button" name="button" id="embed">
+ Embed Video link
+ </button>
</center>
</form>
<hr>
@@ -81,7 +86,7 @@
</div>
<br>
<center>
- <button class="btn" type="submit" id="submit" name="Add">
+ <button class="btn btn-success" type="submit" id="submit" name="Add">
Add to Module
</button>
</center>
@@ -94,34 +99,49 @@
<div id="fixed-added">
<table id="course-details" class="table table-bordered">
<tr>
- <th>Select</th>
+ <th width="5%">Select</th>
<th>Quiz/Lesson</th>
- <th>Order</th>
- <th width="20%">Check Prerequisite
+ <th width="20%">Order</th>
+ <th width="25%" colspan="2">Check Prerequisite
+ <br>
<a href="#" data-toggle="tooltip" id="prereq_msg">
<span class="glyphicon glyphicon-question-sign">
</span> What's This
</a>
</th>
</tr>
+ <tr>
+ <th scope="row">&nbsp;</th>
+ <td>&nbsp;</td>
+ <td>&nbsp;</td>
+ <th>Currently</th>
+ <th>Change</th>
+ </tr>
+ </tr>
{% for unit in learning_units %}
<tr>
<ul class="inputs-list">
<td>
<input type="checkbox" name="delete_list" value="{{unit.id}}">
</td>
- {% if unit.learning_type == "quiz" %}
- <td><span>{{ unit.quiz.description }} ({{unit.learning_type}})
+ {% if unit.type == "quiz" %}
+ <td><span>{{ unit.quiz.description }} ({{unit.type}})
</span></td>
<td><input type="number" name="order" data-item-id="{{unit.id}}" value="{{unit.order}}" step="1"></td>
{% else %}
- <td><span>{{ unit.lesson.name }} ({{unit.learning_type}})
+ <td><span>{{ unit.lesson.name }} ({{unit.type}})
</span></td>
<td><input type="number" name="order" data-item-id="{{unit.id}}" value="{{unit.order}}" step="1"></td>
{% endif %}
<td>
- <input type="checkbox" name="check_prereq" value="{{unit.id}}">
- &nbsp;{{unit.check_prerequisite}}
+ {% if unit.check_prerequisite %}
+ Yes
+ {% else %}
+ No
+ {% endif %}
+ </td>
+ <td>
+ <input type="checkbox" name="check_prereq" value="{{unit.id}}">
</td>
</ul>
</tr>
@@ -131,9 +151,9 @@
</div>
<br>
<center>
- <button id="Remove" name="Remove" class="btn small primary" type="submit">Remove from Module</button>
- <button id="Change" name="Change" class="btn small primary" type="submit"> Change Order</button>
- <button id="Change" name="Change_prerequisite" class="btn small primary" type="submit"> Change Prerequisite</button>
+ <button id="Remove" name="Remove" class="btn btn-danger" type="submit">Remove from Module</button>
+ <button id="Change" name="Change" class="btn btn-info" type="submit"> Change Order</button>
+ <button id="Change" name="Change_prerequisite" class="btn btn-primary" type="submit"> Change Prerequisite</button>
</center>
</div>
</div> <!-- /.row -->
diff --git a/yaksh/templates/yaksh/add_question.html b/yaksh/templates/yaksh/add_question.html
index 4ec9bee..ed69657 100644
--- a/yaksh/templates/yaksh/add_question.html
+++ b/yaksh/templates/yaksh/add_question.html
@@ -8,7 +8,7 @@
{% block script %}
<script src="{{ URL_ROOT }}/static/yaksh/js/add_question.js"></script>
-<script type="text/javascript" async src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-MML-AM_CHTML"></script>
+<script src="{{ URL_ROOT }}/static/yaksh/js/mathjax/MathJax.js?config=TeX-MML-AM_CHTML"></script>
{% endblock %}
{% block onload %} onload='javascript:textareaformat();' {% endblock %}
diff --git a/yaksh/templates/yaksh/complete.html b/yaksh/templates/yaksh/complete.html
index 6c0d878..d0b7e4d 100644
--- a/yaksh/templates/yaksh/complete.html
+++ b/yaksh/templates/yaksh/complete.html
@@ -1,6 +1,7 @@
{% extends "base.html" %}
-{% block pagetitle %}Online Test{% endblock %}
+{% block pagetitle %}<img src="{{ URL_ROOT }}/static/yaksh/images/yaksh_text.png"
+width="80" alt="YAKSH"></img>{% endblock %}
{% block content %}
{% csrf_token %}
{% if paper.questions_answered.all or paper.questions_unanswered.all %}
diff --git a/yaksh/templates/yaksh/course_detail.html b/yaksh/templates/yaksh/course_detail.html
index e9fadbd..cf0ab18 100644
--- a/yaksh/templates/yaksh/course_detail.html
+++ b/yaksh/templates/yaksh/course_detail.html
@@ -9,10 +9,10 @@
{% block script %}
<script language="JavaScript" type="text/javascript" src="{{ URL_ROOT }}/static/yaksh/js/course.js"></script>
<script type="text/javascript" src="{{ URL_ROOT }}/static/yaksh/js/tinymce/js/tinymce/tinymce.min.js"></script>
-<script src="https://code.jquery.com/ui/1.9.1/jquery-ui.js"></script>
+<script src="{{ URL_ROOT }}/static/yaksh/js/jquery-ui.js"></script>
{% endblock %}
{% block css %}
-<link rel="stylesheet" href="https://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">
+<link rel="stylesheet" href="{{ URL_ROOT }}/static/yaksh/css/jquery-ui/jquery-ui.css">
{% endblock %}
{% block content %}
<br/>
diff --git a/yaksh/templates/yaksh/course_modules.html b/yaksh/templates/yaksh/course_modules.html
index 4933113..8e6f5a6 100644
--- a/yaksh/templates/yaksh/course_modules.html
+++ b/yaksh/templates/yaksh/course_modules.html
@@ -65,7 +65,7 @@
<tr>
<ul class="inputs-list">
<td>
- {% if unit.learning_type == "quiz" %}
+ {% if unit.type == "quiz" %}
{{unit.quiz.description}}
{% else %}
{{unit.lesson.name}}
@@ -85,10 +85,10 @@
{% endif %}
</td>
<td>
- {{unit.learning_type|title}}
+ {{unit.type|title}}
</td>
<td>
- {% if unit.learning_type == "quiz" %}
+ {% if unit.type == "quiz" %}
{% if unit.quiz.view_answerpaper %}
<a href="{{ URL_ROOT }}/exam/view_answerpaper/{{ unit.quiz.questionpaper_set.get.id }}/{{course.id}}"><i class="fa fa-eye" aria-hidden="true"></i> Can View </a>
{% else %}
diff --git a/yaksh/templates/yaksh/courses.html b/yaksh/templates/yaksh/courses.html
index a41c8c3..2456433 100644
--- a/yaksh/templates/yaksh/courses.html
+++ b/yaksh/templates/yaksh/courses.html
@@ -29,7 +29,7 @@
<div class="col-sm-3 col-md-2 sidebar">
<ul class="nav nav-sidebar">
{% if type == "courses" %}
- <li><a href="#" id="link_created_courses">Created Courses</a></li>
+ <li><a href="#" id="link_created_courses">My Courses</a></li>
<li><a href="#" id="link_allotted_courses">Allotted Courses</a></li>
{% else %}
<li><a href="{{URL_ROOT}}/exam/manage/courses">View all Courses</a></li>
@@ -38,19 +38,20 @@
<a href="{{URL_ROOT}}/exam/manage/add_course">Add New Course</a>
</li>
<li>
- <a href="{{URL_ROOT}}/exam/manage/courses/all_quizzes/">View all Quizzes</a>
+ <a href="{{URL_ROOT}}/exam/manage/courses/all_quizzes/">Add/View Quizzes</a>
</li>
<li>
- <a href="{{URL_ROOT}}/exam/manage/courses/all_lessons/">View all Lessons</a>
+ <a href="{{URL_ROOT}}/exam/manage/courses/all_lessons/">Add/View Lessons</a>
</li>
<li>
<a href="{{URL_ROOT}}/exam/manage/courses/all_learning_module">
- View all Learning Modules</a>
+ Add/View Modules</a>
</li>
</ul>
</div>
</div>
-<!-- {% if type == "courses" %} -->
+
+{% if type == "courses" %}
<div id="created_courses" style="display: none;">
{% if not courses %}
<center><h4> No new Courses created </h4></center>
@@ -60,7 +61,7 @@
<table id="course-details" class="table table-bordered">
<tr>
<th>Courses</th>
- <th>Lessons/Quizzes</th>
+ <th>Modules</th>
</tr>
{% for course in courses %}
@@ -98,6 +99,11 @@
<br><br>
<ul>
<li>
+ <a href="{{URL_ROOT}}/exam/manage/courses/designcourse/{{course.id}}/">Design Course
+ </a>
+ </li>
+ <br>
+ <li>
<a href="{{URL_ROOT}}/exam/manage/edit_course/{{course.id}}">Edit Course</a>
</li>
<br>
@@ -111,11 +117,6 @@
</li>
<br>
<li>
- <a href="{{URL_ROOT}}/exam/manage/courses/designcourse/{{course.id}}/">Design Course Session
- </a>
- </li>
- <br>
- <li>
<a href="{{URL_ROOT}}/exam/manage/toggle_status/{{ course.id }}/">
{% if course.active %}Deactivate Course {% else %} Activate Course {% endif %}
</a>
@@ -131,9 +132,9 @@
<table id="course-details" class="table table-bordered">
{% if course.get_learning_modules %}
<tr>
- <th>Learning Modules</th>
- <th>Design Learning module</th>
- <th>Learning Units</th>
+ <th>Module</th>
+ <th>Module Design</th>
+ <th>Lessons/Quizzes</th>
</tr>
{% for module in course.get_learning_modules %}
<tr>
@@ -191,7 +192,7 @@
<table id="course-details" class="table table-bordered">
<tr>
<th>Courses</th>
- <th>Lessons/Quizzes</th>
+ <th>Modules</th>
</tr>
{% for course in allotted_courses %}
@@ -233,6 +234,11 @@
<br><br>
<ul>
<li>
+ <a href="{{URL_ROOT}}/exam/manage/courses/designcourse/{{course.id}}/">Design Course
+ </a>
+ </li>
+ <br>
+ <li>
<a href="{{URL_ROOT}}/exam/manage/edit_course/{{course.id}}">Edit Course</a>
</li>
<br>
@@ -262,8 +268,9 @@
<table id="course-details" class="table table-bordered">
{% if course.get_learning_modules %}
<tr>
- <th>Learning Modules</th>
- <th>Design Learning module</th>
+ <th>Module</th>
+ <th>Module Design</th>
+ <th>Lessons/Quizzes</th>
</tr>
{% for module in course.get_learning_modules %}
<tr>
@@ -276,6 +283,21 @@
Add Quizzes/Lessons for {{module.name}}
</a>
</td>
+ <td>
+ {% for unit in module.get_learning_units %}
+ <ul class="inputs-list">
+ <li>
+ {% if unit.type == "quiz" %}
+ <a href="{{URL_ROOT}}/exam/manage/addquiz/{{unit.quiz.id}}/{{course.id}}">
+ {{unit.quiz.description}}</a>
+ {% else %}
+ <a href="{{URL_ROOT}}/exam/manage/courses/edit_lesson/{{unit.lesson.id}}/{{course.id}}">
+ {{unit.lesson.name}}</a>
+ {% endif %}
+ </li>
+ </ul>
+ {% endfor %}
+ </td>
</tr>
{% endfor %} <!-- end for modules -->
{% else %}
@@ -289,7 +311,8 @@
</div>
{% endif %}
</div>
-<!-- {% endif %} -->
+{% endif %}
+<!-- End if all Courses -->
<!-- Show all Quizzes -->
<div id="all_quizzes" >
@@ -413,7 +436,7 @@
{% if module.get_learning_units %}
{% for unit in module.get_learning_units %}
<ul class="list-group">
- {% if unit.learning_type == 'quiz' %}
+ {% if unit.type == 'quiz' %}
{{unit.quiz.description}}
{% else %}
{{unit.lesson.name}}
diff --git a/yaksh/templates/yaksh/design_course_session.html b/yaksh/templates/yaksh/design_course_session.html
index 35e6949..ee530e0 100644
--- a/yaksh/templates/yaksh/design_course_session.html
+++ b/yaksh/templates/yaksh/design_course_session.html
@@ -28,8 +28,8 @@
<table id="course-details" class="table table-bordered">
<tr>
<th width="2%">Select</th>
- <th>Learning Module</th>
- <th>Learning Units</th>
+ <th>Modules</th>
+ <th>Lessons/Quizzes</th>
</tr>
{% for module in learning_modules %}
<ul class="inputs-list">
@@ -40,7 +40,7 @@
{% for unit in module.get_learning_units %}
<ul class="inputs-list">
<li>
- {% if unit.learning_type == "quiz" %}
+ {% if unit.type == "quiz" %}
{{unit.quiz.description}}
{% else %}
{{unit.lesson.name}}
@@ -58,26 +58,34 @@
</div>
<br>
<center>
- <button id="Add" name="Add" class="btn small primary" type="submit">Add to course</button>
+ <button id="Add" name="Add" class="btn btn-success" type="submit">Add to course</button>
</center>
<br><br>
</div>
<div class="col-md-8 col-md-offset-2">
<div id="fixed-added-wrapper">
- <p><u><b>Choosen Lessons and quizzes: (Change Order)</b></u></p>
+ <p><u><b>Choosen Lessons and quizzes:</b></u></p>
<div id="fixed-added">
<table id="course-details" class="table table-bordered">
<tr>
- <th>Select</th>
- <th>Learning Module</th>
- <th>Order</th>
- <th width="20%">Check Prerequisite
+ <th width="5%">Select</th>
+ <th>Module</th>
+ <th width="20%">Order</th>
+ <th width="25%" colspan="2">Check Prerequisite
+ <br>
<a href="#" data-toggle="tooltip" id="prereq_msg">
<span class="glyphicon glyphicon-question-sign">
</span> What's This
</a>
</th>
</tr>
+ <tr>
+ <th scope="row">&nbsp;</th>
+ <td>&nbsp;</td>
+ <td>&nbsp;</td>
+ <th>Currently</th>
+ <th>Change</th>
+ </tr>
{% for module in added_learning_modules %}
<tr>
<ul class="inputs-list">
@@ -89,7 +97,14 @@
<input type="number" name="order" data-item-id="{{module.id}}" value="{{module.order}}" step="1">
</td>
<td>
- <input type="checkbox" name="check_prereq" value="{{module.id}}">&nbsp;{{module.check_prerequisite}}
+ {% if module.check_prerequisite %}
+ Yes
+ {% else %}
+ No
+ {% endif %}
+ </td>
+ <td>
+ <input type="checkbox" name="check_prereq" value="{{module.id}}">
</td>
</ul>
</tr>
@@ -99,9 +114,9 @@
</div>
<br>
<center>
- <button id="Remove" name="Remove" class="btn small primary" type="submit">Remove from course</button>
- <button id="Change" name="Change" class="btn small primary" type="submit"> Change Order</button>&nbsp;&nbsp;
- <button id="Change" name="Change_prerequisite" class="btn small primary" type="submit"> Change Prerequisite</button>
+ <button id="Remove" name="Remove" class="btn btn-danger" type="submit">Remove from course</button>
+ <button id="Change" name="Change" class="btn btn-info" type="submit"> Change Order</button>
+ <button id="Change" name="Change_prerequisite" class="btn btn-primary" type="submit"> Change Prerequisite</button>
</center>
</div>
</div> <!-- /.row -->
diff --git a/yaksh/templates/yaksh/grade_user.html b/yaksh/templates/yaksh/grade_user.html
index a68d348..93f00e0 100644
--- a/yaksh/templates/yaksh/grade_user.html
+++ b/yaksh/templates/yaksh/grade_user.html
@@ -9,8 +9,7 @@
{% block script %}
<script src="{{ URL_ROOT }}/static/yaksh/js/jquery.tablesorter.min.js"></script>
-<script type="text/javascript" async src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-MML-AM_CHTML">
-</script>
+<script src="{{ URL_ROOT }}/static/yaksh/js/mathjax/MathJax.js?config=TeX-MML-AM_CHTML"></script>
<script type="text/javascript">
$(document).ready(function()
{
diff --git a/yaksh/templates/yaksh/intro.html b/yaksh/templates/yaksh/intro.html
index ca49d64..6bd2fab 100644
--- a/yaksh/templates/yaksh/intro.html
+++ b/yaksh/templates/yaksh/intro.html
@@ -25,7 +25,7 @@
<div class="row">
<div class="col-md-6">
<center>
- {% if status == "moderator" %}
+ {% if status != "moderator" %}
<a href="{{URL_ROOT}}/exam/quizzes/view_module/{{module.id}}/{{course.id}}" class="btn btn-primary" name="home">
<span class=" glyphicon glyphicon-arrow-left">
</span>
diff --git a/yaksh/templates/yaksh/login.html b/yaksh/templates/yaksh/login.html
index f40b12f..9c377b9 100644
--- a/yaksh/templates/yaksh/login.html
+++ b/yaksh/templates/yaksh/login.html
@@ -1,6 +1,7 @@
{% extends "base.html" %}
-{% block pagetitle %}YAKSH {% endblock %}
+{% block pagetitle %}<img src="{{ URL_ROOT }}/static/yaksh/images/yaksh_text.png" width="100" alt="YAKSH">
+</img>{% endblock %}
{% block content %}
<div class="row">
@@ -39,7 +40,8 @@
<br/>
<p><b>Fork us at:</b>
<a class = "btn btn-social-icon btn-github"
- href ="https://github.com/fossee/online_test">
+ href ="https://github.com/fossee/online_test"
+ style="color:black">
<span class="fa fa-github" style="font-size:48px"></span>
</p>
diff --git a/yaksh/templates/yaksh/question.html b/yaksh/templates/yaksh/question.html
index c9a5211..fe5917c 100644
--- a/yaksh/templates/yaksh/question.html
+++ b/yaksh/templates/yaksh/question.html
@@ -20,8 +20,7 @@
<script src="{{ URL_ROOT }}/static/yaksh/js/codemirror/mode/python/python.js"></script>
<script src="{{ URL_ROOT }}/static/yaksh/js/codemirror/mode/clike/clike.js"></script>
<script src="{{ URL_ROOT }}/static/yaksh/js/codemirror/mode/shell/shell.js"></script>
-<script type="text/javascript" async src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-MML-AM_CHTML"></script>
-
+<script src="{{ URL_ROOT }}/static/yaksh/js/mathjax/MathJax.js?config=TeX-MML-AM_CHTML"></script>
<script>
init_val = '{{ last_attempt|escape_quotes|safe }}';
lang = "{{ question.language }}"
@@ -99,6 +98,12 @@ function call_skip(url)
form.action = url
form.submit();
}
+init_val = '{{ last_attempt|escape_quotes|safe }}';
+lang = "{{ question.language }}"
+course_id = "{{course.id}}"
+module_id = "{{module.id}}"
+question_type = "{{ question.type }}"
+
</script>
{% endblock script %}
@@ -117,7 +122,7 @@ function call_skip(url)
<span class=" glyphicon glyphicon-edit" data-toggle="tooltip" title="Currently on"></span>
{% endif %}
-{% if unit.learning_type == "quiz" %}
+{% if unit.type == "quiz" %}
<a href="{{ URL_ROOT }}/exam/start/{{unit.quiz.questionpaper_set.get.id}}/{{module.id}}/{{course.id}}">
{{ unit.quiz.description }}
</a>
diff --git a/yaksh/templates/yaksh/quit.html b/yaksh/templates/yaksh/quit.html
index b38c21e..78a9b47 100644
--- a/yaksh/templates/yaksh/quit.html
+++ b/yaksh/templates/yaksh/quit.html
@@ -1,6 +1,7 @@
{% extends "base.html" %}
-{% block pagetitle %} Yaksh Online Test {% endblock %}
+{% block pagetitle %} <img src="{{ URL_ROOT }}/static/yaksh/images/yaksh_text.png"
+width="80" alt="YAKSH"></img> {% endblock %}
{% block content %}
<center><table class="table table-bordered" >
<caption> <center><h3>Submission Status</h3> </center> </caption>
diff --git a/yaksh/templates/yaksh/show_video.html b/yaksh/templates/yaksh/show_video.html
index 1f80e71..0490697 100644
--- a/yaksh/templates/yaksh/show_video.html
+++ b/yaksh/templates/yaksh/show_video.html
@@ -5,41 +5,39 @@
{% block pagetitle %} {{ learning_module.name|title }} {% endblock %}
-{% block usersidebar %}
-<br><br><br>
-<center><h3>Lessons/Quizzes</h3></center>
-<ul class="list">
-{% for unit in learning_units %}
-<span>
-<li>
-{% get_unit_status course learning_module unit user as status %}
+{% block main %}
+<div class="col-sm-3 col-md-2 sidebar">
+ <center><h3>Lessons/Quizzes</h3></center>
+ <ul class="list">
+ {% for unit in learning_units %}
+ <span>
+ <li>
+ {% get_unit_status course learning_module unit user as status %}
-{% if unit.id == current_unit.id %}
- <span class="glyphicon glyphicon-edit" data-toggle="tooltip" title="Currently on">
+ {% if unit.id == current_unit.id %}
+ <span class="glyphicon glyphicon-edit" data-toggle="tooltip" title="Currently on">
+ </span>
+ {% endif %}
+ {% if unit.type == "quiz" %}
+ <a href="{{ URL_ROOT }}/exam/start/{{unit.quiz.questionpaper_set.get.id}}/{{learning_module.id}}/{{course.id}}">
+ {{ unit.quiz.description }}
+ </a>
+ {% else %}
+ <a href="{{ URL_ROOT }}/exam/show_lesson/{{unit.lesson.id}}/{{learning_module.id}}/{{course.id}}">
+ {{ unit.lesson.name }}
+ </a>
+ {% endif %}
+ {% if status == "completed" %}
+ <span class="glyphicon glyphicon-ok" style="color: #7CFC00;"></span>
+ {% else %}
+ <span class="glyphicon glyphicon-remove" style="color: #FF0000"></span>
+ {% endif %}
+ </li>
</span>
-{% endif %}
-{% if unit.learning_type == "quiz" %}
- <a href="{{ URL_ROOT }}/exam/start/{{unit.quiz.questionpaper_set.get.id}}/{{learning_module.id}}/{{course.id}}">
- {{ unit.quiz.description }}
- </a>
-{% else %}
- <a href="{{ URL_ROOT }}/exam/show_lesson/{{unit.lesson.id}}/{{learning_module.id}}/{{course.id}}">
- {{ unit.lesson.name }}
- </a>
-{% endif %}
-{% if status == "completed" %}
- <span class="glyphicon glyphicon-ok" style="color: #7CFC00;"></span>
-{% else %}
- <span class="glyphicon glyphicon-remove" style="color: #FF0000"></span>
-{% endif %}
-</li>
-</span>
-<br>
-{% endfor %}
-</ul>
-{% endblock %}
-
-{% block main %}
+ <br>
+ {% endfor %}
+ </ul>
+</div>
{% if msg %}
<center>
<div class="col-md-12 col-md-offset-1 main">
@@ -48,7 +46,7 @@
{% endif %}
<div class="col-md-12 col-md-offset-1 main">
{% if state == "module" %}
-<div class="panel panel-default">
+<div class="panel panel-default" style="border: none; box-shadow: none;">
<div class="panel-body">
{{learning_module.html_data|safe}}
</div>
@@ -61,11 +59,26 @@
</div>
{% else %}
<center><h3>{{lesson.name}}</h3></center>
-<div class="panel panel-default">
+<div class="panel panel-default" style="border: none; box-shadow: none;">
<div class="panel-body">
{{lesson.html_data|safe}}
</div>
</div>
+{% if lesson.get_files %}
+ <div class="panel" style="border-width: 10px;">
+ <center>
+ <div class="alert alert-success">
+ <h4>Files for this lesson</h4>
+ </div>
+ {% for f in lesson.get_files %}
+ <h4>
+ <b>{{forloop.counter}}.</b>
+ <a href="{{f.file.url}}">{{ f.file.name|file_title }}</a>
+ </h4><br>
+ {% endfor %}
+ </center>
+ </div>
+{% endif %}
<div style="text-align: center;">
<a href="{{ URL_ROOT }}/exam/next_unit/{{course.id}}/{{learning_module.id}}/{{current_unit.id}}" class="btn btn-info" style="display: inline-block;">Next Unit
<span class="glyphicon glyphicon-chevron-right">
diff --git a/yaksh/templates/yaksh/user_data.html b/yaksh/templates/yaksh/user_data.html
index 60269e4..45867d2 100644
--- a/yaksh/templates/yaksh/user_data.html
+++ b/yaksh/templates/yaksh/user_data.html
@@ -7,7 +7,8 @@
{% block script %}
<script src= "{{ URL_ROOT }}/static/yaksh/js/edit_question.js"></script>
-<script type="text/javascript" async src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-MML-AM_CHTML"></script>
+<script src="{{ URL_ROOT }}/static/yaksh/js/mathjax/MathJax.js?config=TeX-MML-AM_CHTML"></script>
+
{% endblock %}
<form action="" method="post">
diff --git a/yaksh/templates/yaksh/view_answerpaper.html b/yaksh/templates/yaksh/view_answerpaper.html
index 49276bab..5f899e3 100644
--- a/yaksh/templates/yaksh/view_answerpaper.html
+++ b/yaksh/templates/yaksh/view_answerpaper.html
@@ -4,7 +4,8 @@
{% block pagetitle %} Answer Paper for {{ quiz.description }}{% endblock pagetitle %}
{% block script %}
-<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-MML-AM_CHTML"></script>
+<script src="{{ URL_ROOT }}/static/yaksh/js/mathjax/MathJax.js?config=TeX-MML-AM_CHTML"></script>
+
{% endblock script %}
{% block main %}