diff options
Diffstat (limited to 'testapp/templates')
32 files changed, 0 insertions, 1519 deletions
diff --git a/testapp/templates/404.html b/testapp/templates/404.html deleted file mode 100644 index 7d33dd3..0000000 --- a/testapp/templates/404.html +++ /dev/null @@ -1,5 +0,0 @@ -{% extends "base.html" %} - -{% block content %} -The requested page does not exist. -{% endblock %} diff --git a/testapp/templates/500.html b/testapp/templates/500.html deleted file mode 100644 index d02721f..0000000 --- a/testapp/templates/500.html +++ /dev/null @@ -1,7 +0,0 @@ -{% extends "base.html" %} - -{% block content %} -Internal Server error.<br /> -This event will be reported.<br /> -Sorry for the inconvinience. -{% endblock %} diff --git a/testapp/templates/base.html b/testapp/templates/base.html deleted file mode 100644 index 3dfbe10..0000000 --- a/testapp/templates/base.html +++ /dev/null @@ -1,46 +0,0 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" -"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> - -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> - <head> - <title> - {% block title %} - {% endblock %} - </title> - - {% block meta %} - <meta charset="utf-8"> - <meta name="description" content=""> - <meta name="author" content=""> - {% endblock %} - - <link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/base.css" type="text/css" /> - {% block css %} - {% endblock %} - - {% block script %} - {% endblock %} - </head> - -<body {% block onload %}{% endblock %}> - <div class="container"> - <div class="content"> - <div class="page-header"> - <h1><Strong><center>{% block pagetitle %} {% endblock pagetitle %}</center></strong></h1> - </div> - <div class=row> - <div class=span14> - <h3><center>{% block formtitle %} {% endblock formtitle %}</center></h3><br> - {% block content %} - {% endblock %} - </div> - </div> - </div> - <footer> - <p>© FOSSEE group, IIT Bombay</p> - </footer> - </div> - -</body> -</html> - diff --git a/testapp/templates/exam/add_question.html b/testapp/templates/exam/add_question.html deleted file mode 100644 index b0b22b1..0000000 --- a/testapp/templates/exam/add_question.html +++ /dev/null @@ -1,41 +0,0 @@ -{% extends "manage.html" %} - - -{% block subtitle %}Add Question{% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question_quiz.css" type="text/css" /> -<link rel="stylesheet" media="all" type="text/css" href="{{ URL_ROOT }}/static/exam/css/autotaggit.css" /> -{% endblock %} - -{% block script %} -<script type="text/javascript" src="{{ URL_ROOT }}/static/exam/js/min.js"></script> -<script src="/static/taggit_autocomplete_modified/jquery.min.js" type="text/javascript"></script> -<script src="/static/taggit_autocomplete_modified/jquery.autocomplete.js" type="text/javascript"></script> -<script src="{{ URL_ROOT }}/static/exam/js/add_question.js"></script> -{% endblock %} - -{% block onload %} onload='javascript:textareaformat();' {% endblock %} - -{% block manage %} -<form action="" method="post" name=frm onSubmit="return autosubmit();"> - {% csrf_token %} - <center><table class=span1> - <tr><td>Summary: <td>{{ form.summary }}{{ form.summary.errors }} - <tr><td> Language: <td> {{form.language}}{{form.language.errors}} - <tr><td> Active: <td> {{ form.active }}{{form.active.errors}} Type: {{ form.type }}{{form.type.errors}} - <tr><td>Points:<td><button class="btn-mini" type="button" onClick="increase(frm);">+</button>{{ form.points }}<button class="btn-mini" type="button" onClick="decrease(frm);">-</button>{{ form.points.errors }} - <tr><td><strong>Rendered: </strong><td><p id='my'></p> - <tr><td>Description: <td>{{ form.description}} {{form.description.errors}} - <tr><td>Test: <td>{{ form.test }}{{form.test.errors}} - <tr><td>Snippet: <td>{{ form.snippet }}{{ form.snippet.errors }}</td></tD></td></tr> - <tr><td>Tags: <td>{{ form.tags }} - <tr><td id='label_option'>Options: <td>{{ form.options }} {{form.options.errors}} - - - </table></center> - <center><button class="btn" type="submit" name="savequestion">Save</button> - <button class="btn" type="button" name="button" onClick='location.replace("{{URL_ROOT}}/exam/manage/questions/");'>Cancel</button> </center> -</form> -{% endblock %} - diff --git a/testapp/templates/exam/add_questionpaper.html b/testapp/templates/exam/add_questionpaper.html deleted file mode 100644 index 4cce8a9..0000000 --- a/testapp/templates/exam/add_questionpaper.html +++ /dev/null @@ -1,28 +0,0 @@ -{% extends "manage.html" %} - - -{% block subtitle %}Design Question Paper{% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question_quiz.css" type="text/css" /> -<link rel="stylesheet" media="all" type="text/css" href="{{ URL_ROOT }}/static/exam/css/autotaggit.css" /> -{% endblock %} -{% block script %} -<script src="/static/taggit_autocomplete_modified/jquery.min.js" type="text/javascript"></script> -<script src="/static/taggit_autocomplete_modified/jquery.autocomplete.js" type="text/javascript"></script> -<script src="{{ URL_ROOT }}/static/exam/js/add_questionpaper.js"></script> -{% endblock %} - -{% block manage %} -<input type=hidden id="url_root" value={{ URL_ROOT }}> -<form> -{% csrf_token %} -Select mode to design Question Paper: -<select name='mode' id='mode' onChange='javascript:load_data();'> - <option>---------</option> - <option>Automatic</option> - <option>Manual</option> -</select> -</form> - -{% endblock %} diff --git a/testapp/templates/exam/add_quiz.html b/testapp/templates/exam/add_quiz.html deleted file mode 100644 index c2533de..0000000 --- a/testapp/templates/exam/add_quiz.html +++ /dev/null @@ -1,25 +0,0 @@ -{% extends "manage.html" %} - - -{% block subtitle %}Add Quiz{% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question_quiz.css" type="text/css" /> -{% endblock %} -{% block script %} -<script src="{{ URL_ROOT }}/static/exam/js/add_quiz.js"></script> -{% endblock %} -{% block onload %} onload="javascript:test();" {% endblock %} -{% block manage %} -<form name=frm id=frm action="" method="post" > - {% csrf_token %} - <center> - <table class=span1> - {{ form.as_table }} - </table> - </center> - - <center><button class="btn" type="submit" id="submit" name="questionpaper">Design Question Paper</button> - <button class="btn" type="button" name="button" onClick='location.replace("{{URL_ROOT}}/exam/manage/showquiz/");'>Cancel</button> </center> -</form> -{% endblock %} diff --git a/testapp/templates/exam/ajax_marks.html b/testapp/templates/exam/ajax_marks.html deleted file mode 100644 index 716bb88..0000000 --- a/testapp/templates/exam/ajax_marks.html +++ /dev/null @@ -1,4 +0,0 @@ -<option value='select'>Select Marks</option> -{% for mark in marks %} -<option value="{{ mark.0 }}"> {{ mark.0 }} </option> -{% endfor %} diff --git a/testapp/templates/exam/ajax_questions.html b/testapp/templates/exam/ajax_questions.html deleted file mode 100644 index e343f9b..0000000 --- a/testapp/templates/exam/ajax_questions.html +++ /dev/null @@ -1,31 +0,0 @@ -<div id="questions"> - {% if questions %} - <input type="checkbox" id="checkall" class="ignore"> - <span><b> <font size="3"> Select All </font></b></span> - {% endif %} - <ul class="inputs-list"> - - {% for question in questions %} - <li> - <label> - <input type="checkbox" name="questions" data-qid="{{question.id}}"> - <span> {{ question.summary }} </span> - </label> - </li> - {% endfor %} - </ul> -</div> - -<div id="num"> - <select id="numbers"> - <option value="">Number of questions to be picked from the pool</option> - {% for q in questions %} - {% if forloop.counter0 != 0 %} - <option value={{forloop.counter0}}>{{ forloop.counter0}}</option> - {% endif %} - {% if questions|length == 1%} - <option value=1>1</option> - {% endif %} - {% endfor %} - </select> -</div> diff --git a/testapp/templates/exam/automatic_questionpaper.html b/testapp/templates/exam/automatic_questionpaper.html deleted file mode 100644 index fcd3db5..0000000 --- a/testapp/templates/exam/automatic_questionpaper.html +++ /dev/null @@ -1,88 +0,0 @@ -{% extends "manage.html" %} - - -{% block subtitle %}Design Question Paper{% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question_quiz.css" type="text/css" /> -<link rel="stylesheet" media="all" type="text/css" href="{{ URL_ROOT }}/static/exam/css/autotaggit.css" /> -<style> -select -{ - width:auto; -} -</style> -{% endblock %} -{% block script %} -<script src="/static/taggit_autocomplete_modified/jquery.min.js" type="text/javascript"></script> -<script src="/static/taggit_autocomplete_modified/jquery.autocomplete.js" type="text/javascript"></script> -<script src="{{ URL_ROOT }}/static/exam/js/add_questionpaper.js"></script> -{% endblock %} - -{% block manage %} -<input type=hidden id="url_root" value={{ URL_ROOT }}> -<center><b>Automatic mode to design the Question Paper</center><br> -<form action="" method="post" name=frm> - {% csrf_token %} - <center> - Tag Conditions: - <select name='first_tag'> - <option value="">Select Tag </option> - {% for tag in data.tags %} - <option value={{tag}}>{{tag}}</option> - {% endfor %} - </select> - - <select name='first_condition'> - <option value="or">OR</option> - <option value="and">AND</option> - </select> - - <select name='second_tag'> - <option value="">Select Tag </option> - {% for tag in data.tags %} - <option value={{tag}}>{{tag}}</option> - {% endfor %} - </select> - - <select name='second_condition'> - <option value="or">OR</option> - <option value="and">AND</option> - </select> - - <select name='third_tag'> - <option value="null">Select Tag </option> - {% for tag in data.tags %} - <option value={{tag}}>{{tag}}</option> - {% endfor %} - </select> - </center> - - <br> - - <center>Number of question: <input type=text id=num_questions name='num_questions' style="width:25px;"> <button class=btn type=submit name='fetch' value='fetch'>Fetch Questions</button><br></center> - - <br> - <br> - <p><b>Below is the list of Questions fetched according to the given tag conditions</p> - <hr> - <center><table class=span10> - <th>Summary - <th>Type - <th>Points - <th>Tags - {% for question in data.questions %} - <input type=hidden name='questions' value={{ question.id }} /> - <tr><td>{{ question.summary }} <td>{{ question.type }} <td>{{ question.points }} <td> - {% for tag in question.tags.all %} - {{ tag }} - {% endfor %} - </tr> - <br> - {% endfor %} - </table> - {% if data.msg %}<div class="alert alert-error">{{ data.msg }}</div>{% endif %} - <center><button class=btn type=submit name='save' value='save'>Save Question Paper</button></center> -</form> - -{% endblock %} diff --git a/testapp/templates/exam/complete.html b/testapp/templates/exam/complete.html deleted file mode 100644 index 1d5df3c..0000000 --- a/testapp/templates/exam/complete.html +++ /dev/null @@ -1,12 +0,0 @@ -{% extends "base.html" %} - -{% block title %}Good bye!{% endblock %} - -{% block pagetitle %}Online Test{% endblock %} -{% block content %} -{% csrf_token %} - <center><h2> Good bye! </h2></center> - <center><h4> {{message}} </h4></center> - <center><h4>You may now close the browser.</h4></center><br> - <center><a href="{{URL_ROOT}}/exam/"> Login Again </a></center> -{% endblock content %} diff --git a/testapp/templates/exam/design_questionpaper.html b/testapp/templates/exam/design_questionpaper.html deleted file mode 100644 index 8994148..0000000 --- a/testapp/templates/exam/design_questionpaper.html +++ /dev/null @@ -1,184 +0,0 @@ -{% extends "manage.html" %} - -{% block subtitle %}Design Question Paper{% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/base.css" type="text/css" /> -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question_quiz.css" type="text/css" /> -<link rel="stylesheet" media="all" type="text/css" href="{{ URL_ROOT }}/static/exam/css/autotaggit.css" /> -<link rel="stylesheet" media="all" type="text/css" href="{{ URL_ROOT }}/static/exam/css/question_paper_creation.css" /> -<style> -select -{ - width:auto; -} -</style> -{% endblock %} -{% block script %} -<script src="/static/taggit_autocomplete_modified/jquery.min.js" type="text/javascript"></script> -<script src="/static/taggit_autocomplete_modified/jquery.autocomplete.js" type="text/javascript"></script> - - -<script src="{{ URL_ROOT }}/static/exam/js/bootstrap-tabs.js"></script> -<script src="{{ URL_ROOT }}/static/exam/js/add_questionpaper.js"></script> -<script src="{{ URL_ROOT }}/static/exam/js/question_paper_creation.js"></script> -<script src="{{ URL_ROOT }}/static/exam/js/bootstrap-modal.js"></script> -{% endblock %} - -{% block manage %} -<input type=hidden id="url_root" value={{ URL_ROOT }}> -<center><b>Manual mode to design the {{lang}} Question Paper</center><br> - <ul class="tabs" data-tabs="tabs"> - <li class="active" id="fixed-tab"> - <a href="#fixed-questions" id="fixed"> - STEP 1<br> - Add Fixed Questions - </a> - </li> - <li id="random-tab"> - <a href="#random-questions" id="random"> - STEP 2<br> - Add Random Questions - </a> - </li> - <li id="finish-tab"> - <a href="#finish" id="finished"> - STEP 3<br> - Finish - </a></li> -</ul> - -<form action="{{URL_ROOT}}/exam/manage/designquestionpaper/" method="post" name=frm > {% csrf_token %} - <div> - <h3>Total Marks: <span id="total_marks" class="well">0</span></h3> - </div> -<div class="tab-content"> - <!-- common to fixed and random questions --> - <div class="row" id="selectors"> - <h5 style="padding-left: 20px;">Please select Question type and Marks</h5> - <div class="span4"> - {{ form.question_type }} - </div> <!-- /.span4 --> - <div class="span4"> - {{ form.marks }} - </div> <!-- /.span4 --> - <div class="span4"> - <div class="pull-left" id="number-wrapper"></div> - </div> <!-- /.span4 --> - </div> <!-- /.row --> - <br><br> - - - <div class="tab-pane active" id="fixed-questions"> - <div class="row"> - <div class="span7"> - <div id="fixed-available-wrapper"> - <p><u>Select questions to add:</u></p> - <div id="fixed-available"> - </div> - <a id="add-fixed" class="btn small primary pull-right" href="#">Add to paper</a> - </div> - </div> - <div class="span7"> - <div id="fixed-added-wrapper"> - <p><u>Fixed questions currently in paper:</u></p> - <div id="fixed-added"> - </div> - </div> - </div> - </div> <!-- /.row --> - <br> - <div class="pull-right"> - <a class="btn" id="fixed-next">Next ></a> - </div> - - </div> <!-- /#fixed-questions --> - - - <div class="tab-pane" id="random-questions"> - <div class="row"> - <div class="span7"> - <div id="random-available-wrapper"> - <p><u>Select questions to add to the pool:</u></p> - <div id="random-available"> - </div> - <a id="add-random" class="btn small primary pull-right" href="#">Add to paper</a> - </div> - </div> - <div class="span7"> - <div id="random-added-wrapper"> - <p><u>Pool of questions currently in paper:</u></p> - <div id="random-added"> - </div> - </div> - </div> - </div> <!-- /.row --> - <br> - <div class="pull-left"> - <a class="btn" id="random-prev">< Previous</a> - </div> - <div class="pull-right"> - <a class="btn" id="random-next">Next ></a> - </div> - </div> <!-- /#random-questions --> - - <div class="tab-pane" id="finish"> - <center> - <h5>Almost finished creating your question paper</h5> - <label style="float: none;"> - {{ form.shuffle_questions }} - <span>Auto shuffle.</span> - </label> <br><br> - <input class ="btn primary large" type="button" id="preview" value="Preview question paper"> - <input class ="btn primary large" type="button" id="save" value="Save question paper"> - <br> - <div class="pull-left"> - <a class="btn" id="finish-prev">< Previous</a> - </div> - </center> - </div> <!-- /#finish --> -</div> -<!-- /.tab-content --> -</form> -<br> -<div class="clearfix"></div> - -<!-- Modal --> -<div class="modal fade " id="myModal" > - <div class="modal-dialog"> - <div class="modal-content"> - <div class="modal-header"> - <h4 class="modal-title" id="myModalLabel">Question Paper Preview</h4> - </div> - <div id = "modal_body"class="modal-body"> - </div> - <div class="modal-footer"> - <button type="button" class="btn primary close" data-dismiss="modal">OK</button> - </div> - </div> - </div> -</div> - -<div class="modal fade " id="modalSave" > - <div class="modal-dialog"> - <div class="modal-content"> - <div class="modal-header"> - <h4 class="modal-title" id="myModalLabel">Cannot Save</h4> - </div> - <div id = "modal_body"class="modal-body"> - Please select questions for your paper - </div> - <div class="modal-footer"> - <button type="button" class="btn primary close" data-dismiss="modal">OK</button> - </div> - </div> - </div> -</div> -</div> - -<script> - $(function () { - $('.tabs').tabs() - }) -</script> -{% endblock %} diff --git a/testapp/templates/exam/edit_question.html b/testapp/templates/exam/edit_question.html deleted file mode 100644 index b28cc3e..0000000 --- a/testapp/templates/exam/edit_question.html +++ /dev/null @@ -1,54 +0,0 @@ -{% extends "manage.html" %} - -{% block subtitle %}Edit Question{% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question_quiz.css" type="text/css" /> -<link rel="stylesheet" media="all" type="text/css" href="{{ URL_ROOT }}/static/exam/css/autotaggit.css" /> -{% endblock %} -{% block script %} -<script src="{{ URL_ROOT }}/static/exam/js/edit_question.js"></script> -<script src="/static/taggit_autocomplete_modified/jquery.min.js" type="text/javascript"></script> -<script src="/static/taggit_autocomplete_modified/jquery.autocomplete.js" type="text/javascript"></script> -{% endblock %} - -{% block onload %} onload = 'javascript:textareaformat();' {% endblock %} - -{% block manage %} -<form name='frm' action="{{URL_ROOT}}/exam/manage/editquestion/" method="post" onSubmit="return autosubmit()" onKeyPress='javascript:render_question(frm);'> - {% csrf_token %} -<center><p>Click on the Question links to edit the question.</p></center> - -<table> - - {% for form in forms %} - - <tr><td height=10><a id='a{{forloop.counter}}' onClick="data('contentDiv{{forloop.counter}}','myContent{{forloop.counter}}','a{{forloop.counter}}','{{form.summary.value}}');" style='cursor:pointer;'>{{form.summary.value}}</a> - - <div id="contentDiv{{forloop.counter}}" style="display:none;"> - <div id="myContent{{forloop.counter}}" style="display: none;"> - - <center><table class=span1> - <tr><td><b>Summary:</b> <td>{{ form.summary }}{{ form.summary.errors }} - <tr><td><b> Language: </b><td> {{form.language}}{{form.language.errors}} - <tr><td><b> Active: </b><td> {{ form.active }}{{form.active.errors}} Type: {{ form.type }}{{form.type.errors}} - <tr><td><b>Points:<td><button class="btn-mini" name={{forloop.counter}} type="button" onClick="increase(frm,{{forloop.counter}});">+</button>{{ form.points }}<button class="btn-mini" type="button" onClick="decrease(frm,{{forloop.counter}});">-</button>{{ form.points.errors }} - <tr><td><strong>Rendered: </strong><td><p id='my{{forloop.counter}}'></p> - <tr><td><b>Description: <td>{{ form.description }} {{form.description.errors}} - <tr><td><b>Test: <td>{{ form.test }}{{form.test.errors}} - <tr><td><b>Snippet: <td>{{ form.snippet }}{{ form.snippet.errors }}</td></b></td></tr> - <tr><td><b>Tags: </b><td>{{ form.tags }} - <tr><td id='label_option{{forloop.counter}}'><b>Options:<td>{{ form.options }} {{form.options.errors}} {{form.options.helptext}} - </table></center> - </div> - </div> - {% endfor %} -</table></center> -{% for i in data %} - <input type=hidden name='questions' value="{{ i }}" /> -{% endfor %} - - <center><button class="btn" type="submit" name="savequestion">Save</button> - <button class="btn" type="button" name="button" onClick='location.replace("{{URL_ROOT}}/exam/manage/questions/");'>Cancel</button> </center> -</form> -{% endblock %} diff --git a/testapp/templates/exam/edit_quiz.html b/testapp/templates/exam/edit_quiz.html deleted file mode 100644 index 6445907..0000000 --- a/testapp/templates/exam/edit_quiz.html +++ /dev/null @@ -1,39 +0,0 @@ -{% extends "manage.html" %} - - -{% block subtitle %}Edit Quiz(zes){% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question_quiz.css" type="text/css" /> -{% endblock %} - -{% block script %} -<script src="{{ URL_ROOT }}/static/exam/js/edit_quiz.js"></script> -{% endblock %} - -{% block onload %} onload = 'javascript:form_load();' {% endblock %} - -{% block manage %} -<form name=frm action="{{URL_ROOT}}/exam/manage/editquiz/" method="post"> - {% csrf_token %} - <center> - <table class=span1> - {% for form in forms %} - <tr><td><b>Start Date: <td>{{ form.start_date}} - <tr><td><b>Duration: <td> {{ form.duration }}<br>{{form.duration.help_text}} - <tr><td><b>Active: <td> {{ form.active }} - <tr><td><b>Description: <td> {{ form.description }} - <tr><td><b>Passing Criteria: <td> {{ form.pass_criteria }}<br>{{form.pass_criteria.help_text}} - <tr><td><b>Language: <td> {{ form.language }} - <tr><td><b>Prerequisite: <td> {{ form.prerequisite }} - <hr> - {% endfor %} - </table> - </center> -{% for i in data %} - <input type=hidden name='quizzes' value="{{ i }}" /> -{% endfor %} - <center><button class="btn" type="submit" name="save">Save</button> - <button class="btn" type="button" name="button" onClick='location.replace("{{URL_ROOT}}/exam/manage/showquiz/");'>Cancel</button> </center> -</form> -{% endblock %} diff --git a/testapp/templates/exam/editquestionpaper.html b/testapp/templates/exam/editquestionpaper.html deleted file mode 100644 index 819ff06..0000000 --- a/testapp/templates/exam/editquestionpaper.html +++ /dev/null @@ -1,21 +0,0 @@ -{% extends "manage.html" %} - - -{% block subtitle %}Questions in "{{ papers.quiz.description }}"{% endblock %} - -{% block script %} -<script src="{{ URL_ROOT }}/static/exam/js/show_question.js"></script> -{% endblock %} - -{% block manage %} -<form name=frm action="" method="post"> -{% csrf_token %} - -{% for i in papers.questions %} -<input type="checkbox" name="papers" value="{{ i.id }}"> <a href="{{URL_ROOT}}/exam/manage/addquestion/{{ i.id }}">{{ i.summary}}</a><br> -{% endfor %} -<br> -<button class="btn" type="submit" name='add' value=add>Add Question</button> -<button class="btn" type="submit" onClick="return confirm_delete(frm);" name='delete' value='delete'>Delete Selected</button> -</form> -{% endblock %} diff --git a/testapp/templates/exam/grade_user.html b/testapp/templates/exam/grade_user.html deleted file mode 100644 index ae9274e..0000000 --- a/testapp/templates/exam/grade_user.html +++ /dev/null @@ -1,94 +0,0 @@ -{% extends "manage.html" %} - -{% block title %} Grading papers for {{ data.user.get_full_name.title }} {% endblock title %} - -{% block subtitle %}Grading papers for {{ data.user.get_full_name.title }}{% endblock %} - -{% block css %} - <link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/gradeuser.css" type="text/css" /> -{% endblock %} - -{% block script %} -<script src= "{{ URL_ROOT }}/static/exam/js/edit_question.js"></script> -{% endblock %} -{% block manage %} - -<p> -Name: {{ data.user.get_full_name.title }} -{% if data.profile %} -(roll number: {{ data.profile.roll_number }}) <br/> -{{ data.profile.position }}, -{{ data.profile.department }}, -{{ data.profile.institute }} -{% endif %} -</p> - -{% if data.papers %} - -{% for paper in data.papers %} - -<h2> Quiz: {{ paper.quiz.description }} </h2> - -<p> -Questions correctly answered: {{ paper.get_answered_str }} <br/> -Total attempts at questions: {{ paper.answers.count }} <br/> -Marks obtained: {{ paper.get_total_marks }} <br/> -Start time: {{ paper.start_time }} <br/> -</p> - -{% if paper.answers.count %} -<h3> Answers </h3><br> -<form name=frm id="q{{ paper.quiz.id }}_form" - action="{{URL_ROOT}}/exam/manage/gradeuser/{{data.user.username}}/" method="post"> -{% csrf_token %} -{% for question, answers in paper.get_question_answers.items %} -<div class="for-question"> -<p><strong> - Question: {{ question.id }}. {{ question.summary }} (Points: {{ question.points }}) -</strong> -<strong><a href="" onClick="grade_data('myContent{{question.id}}'); return false;" style="cursor:pointer;" />Details</strong></p></a> -<div id="contentDiv"> - <div id="myContent{{question.id}}" style="padding:5px; display:none;"> - <p> Description : {{ question.description }} </p> - <p> Test : {{ question.test }} </p> - </div> -</div> -<div class="question-form"> - -{% if question.type == "mcq" %} -<br> -<p> Choices: -{% for option in question.options.strip.splitlines %} {{option}}, {% endfor %} -</p> -<p>Student answer: {{ answers.0 }}</p> -{% else %}{# non-mcq questions #} -<pre> -{% for answer in answers %}################################################################################ -{{ answer.answer.strip }} -# Autocheck: {{ answer.error }} -{% endfor %}</pre> -{% endif %} {# if question.type #} -{% with answers|last as answer %} -Marks: <input id="q{{ question.id }}" type="text" - name="q{{ question.id }}_marks" size="4" - value="{{ answer.marks }}"><br><br> -{% endwith %} -</div> -</div> -{% endfor %} {# for question, answers ... #} - - -<h3>Teacher comments: </h3> -<textarea id="comments_{{paper.question_paper.id}}" rows="10" cols="80" - name="comments_{{ paper.question_paper.id }}">{{ paper.comments }}</textarea> -<br> -<br><button class="btn" type="submit" name="submit_{{paper.quiz.id}}">Save Marks</button> - -</form> -{% endif %} {# if paper.answers.count #} - -{% endfor %} {# for paper in data.papers #} - -{% endif %} {# if data.papers #} - -{% endblock%} diff --git a/testapp/templates/exam/intro.html b/testapp/templates/exam/intro.html deleted file mode 100644 index ec1888a..0000000 --- a/testapp/templates/exam/intro.html +++ /dev/null @@ -1,34 +0,0 @@ -{% extends "base.html" %} - -{% block title %}Instructions and Rules {% endblock %} -{% block pagetitle %}Online Test {% endblock %} -{% block formtitle %}Important instructions & rules {% endblock %} -{% block content %} - - - - <p> Welcome <strong>{{user.first_name.title}} {{user.last_name.title}}</strong>, to the programming quiz! </p> - <p> - This examination system has been developed with the intention of making you - learn programming and be assessed in an interactive and fun manner. - You will be presented with a series of programming questions and problems that - you will answer online and get immediate feedback for. - </p> - <p> Here are some important instructions and rules that you should understand carefully.</p> - <ul> - <li>For any programming questions, you can submit solutions as many times as you want without a penalty. You may skip questions and solve them later. - </li> - <li> You <strong>may</strong> use your computer's Python/IPython shell or an editor to solve the problem and cut/paste the solution to the web interface. - </li> - <li> <strong>You are <strong>not allowed</strong> to use any internet resources, i.e. no google etc.</strong> </li> - <li> Do not copy or share the questions or answers with anyone until the exam is complete <strong>for everyone</strong>.</li> - <li> <strong>All</strong> your attempts at the questions are logged. Do not try to outsmart and break the testing system. If you do, we know who you are and we will expell you from the course. You have been warned. - </li> - </ul> - <p> We hope you enjoy taking this exam !!!</p> - - <form action="{{URL_ROOT}}/exam/start/{{ paper_id }}/" method="post" align="center"> - {% csrf_token %} - <center><button class="btn" type="submit" name="start">Start Exam!</button></center> - </form> -{% endblock content %} diff --git a/testapp/templates/exam/login.html b/testapp/templates/exam/login.html deleted file mode 100644 index 078e7a7..0000000 --- a/testapp/templates/exam/login.html +++ /dev/null @@ -1,22 +0,0 @@ -{% extends "base.html" %} - -{% block title %}Login{% endblock title %} -{% block pagetitle %} Online Test {% endblock %} -{% block formtitle %}Login{% endblock %} -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/login.css" type="text/css" /> -{% endblock %} -{% block content %} - - <form action="" method="post"> - {% csrf_token %} - - <center><table class=span1> - {{ form.as_table }} - </table></center> - <center><button class="btn" type="submit">Login</button> <button class="btn" type="reset">Cancel</button></center> - <br><center><a href="{{URL_ROOT}}/exam/forgotpassword/">Forgot Password?</a></center><br> - <center><a href="{{URL_ROOT}}/exam/register/">New User? Sign-Up </a></center> - </form> - -{% endblock content %} diff --git a/testapp/templates/exam/manual_questionpaper.html b/testapp/templates/exam/manual_questionpaper.html deleted file mode 100644 index 1a1f95c..0000000 --- a/testapp/templates/exam/manual_questionpaper.html +++ /dev/null @@ -1,81 +0,0 @@ -{% extends "manage.html" %} - - -{% block subtitle %}Design Question Paper{% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question_quiz.css" type="text/css" /> -<link rel="stylesheet" media="all" type="text/css" href="{{ URL_ROOT }}/static/exam/css/autotaggit.css" /> -<style> -select -{ - width:auto; -} -</style> -{% endblock %} -{% block script %} -<script src="/static/taggit_autocomplete_modified/jquery.min.js" type="text/javascript"></script> -<script src="/static/taggit_autocomplete_modified/jquery.autocomplete.js" type="text/javascript"></script> - -<script src="{{ URL_ROOT }}/static/exam/js/add_questionpaper.js"></script> -{% endblock %} - -{% block manage %} -<input type=hidden id="url_root" value={{ URL_ROOT }}> -<center><b>Manual mode to design the Question Paper</center><br> - -<form action="" method="post" name=frm> - {% csrf_token %} - <center> - Tag Conditions: - <select name='first_tag'> - <option value="">Select Tag </option> - {% for tag in data.tags %} - <option value={{tag}}>{{tag}}</option> - {% endfor %} - </select> - <select name='first_condition'> - <option value="or">OR</option> - <option value="and">AND</option> - </select> - <select name='second_tag'> - <option value="">Select Tag </option> - {% for tag in data.tags %} - <option value={{tag}}>{{tag}}</option> - {% endfor %} - </select> - <select name='second_condition'> - <option value="or">OR</option> - <option value="and">AND</option> - </select> - <select name='third_tag'> - <option value="null">Select Tag </option> - {% for tag in data.tags %} - <option value={{tag}}>{{tag}}</option> - {% endfor %} - </select> - </center> - <br> - <center><button class=btn type=submit name='fetch' value='fetch'>Fetch Questions</button> - <br><br><b>Below is the list of Questions fetched according to the given tag conditions</b></center> - <hr> - <center><table class=span10> - <th> - <th>Summary - <th>Type - <th>Points - <th>Tags - {% for question in data.questions %} - <tr><td><input type=checkbox name=questions value={{question.id}}> <td> {{ question.summary }} <td>{{ question.type }} <td>{{ question.points }} <td> - {% for tag in question.tags.all %} - {{ tag }} - {% endfor %} - </tr> - <br> - {% endfor %} - </table> - {% if data.msg %}<div class="alert alert-error">{{ data.msg }}</div>{% endif %} - <center><button class=btn type=submit name='save' value='save'>Save Question Paper</button></center> -</form> - -{% endblock %} diff --git a/testapp/templates/exam/monitor.html b/testapp/templates/exam/monitor.html deleted file mode 100644 index ecdb852..0000000 --- a/testapp/templates/exam/monitor.html +++ /dev/null @@ -1,69 +0,0 @@ -{% extends "manage.html" %} - -{% block title %} Quiz results {% endblock title %} - -{% block meta %} <meta http-equiv="refresh" content="30"/> {% endblock meta %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question_quiz.css" type="text/css" /> -{% endblock %} -{% block subtitle %} - {% if not quizzes and not quiz %} - Quiz Results - {% endif %} - {% if quizzes %} - Available Quizzes - {% endif %} - {% if quiz %} - {{ quiz.description }} Results - {% endif %} -{% endblock %} -{% block manage %} - {% if not quizzes and not quiz %} - <center><h5> No quizzes available. </h5></center> - {% endif %} - -{# ############################################################### #} -{# This is rendered when we are just viewing exam/monitor #} -{% if quizzes %} -<ul> -{% for q in quizzes %} -<li><a href="{{URL_ROOT}}/exam/manage/monitor/{{q.id}}/">{{ q.quiz.description }}</a></li> -{% endfor %} -</ul> -{% endif %} - -{# ############################################################### #} -{# This is rendered when we are just viewing exam/monitor/quiz_num #} -{% if quiz %} - -{% if papers %} -{# <p> Quiz: {{ quiz_name }}</p> #} -<p>Number of papers: {{ papers|length }} </p> -<table border="1" cellpadding="3"> - <tr> - <th> Name </th> - <th> Username </th> - <th> Roll number </th> - <th> Institute </th> - <th> Questions answered </th> - <th> Marks obtained </th> - <th> Attempts </th> - </tr> - {% for paper in papers %} - <tr> - <td> <a href="{{URL_ROOT}}/exam/manage/user_data/{{paper.user.username}}">{{ paper.user.get_full_name.title }}</a> </td> - <td> <a href="{{URL_ROOT}}/exam/manage/user_data/{{paper.user.username}}">{{ paper.user.username }}</a> </td> - <td> {{ paper.profile.roll_number }} </td> - <td> {{ paper.profile.institute }} </td> - <td> {{ paper.get_answered_str }} </td> - <td> {{ paper.marks_obtained }} </td> - <td> {{ paper.answers.count }} </td> - </tr> - {% endfor %} -</table> -{% else %} -<p> No answer papers so far. </p> -{% endif %} {# if papers #} -{% endif %} -{% endblock %} diff --git a/testapp/templates/exam/question.html b/testapp/templates/exam/question.html deleted file mode 100644 index a3e8629..0000000 --- a/testapp/templates/exam/question.html +++ /dev/null @@ -1,138 +0,0 @@ -{% extends "base.html" %} - -<!DOCTYPE html> - -{% block title %} Answer question {% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question.css" type="text/css" /> - -{% endblock %} - -{% block script %} -<script src="{{ URL_ROOT }}/static/exam/js/question.js"></script> - -<script> -var time_left = {{ time_left }} -function secs_to_time(secs) -{ - var h = Math.floor(secs/3600); - var h_s = (h > 0) ? h+'h:' : ''; - var m = Math.floor((secs%3600)/60); - var m_s = (m > 0) ? m+'m:' : ''; - var s_s = Math.floor(secs%60) + 's'; - return h_s + m_s + s_s; -} - -function update_time() -{ - time_left -= 1; - if (time_left) - { - var elem = document.getElementById("time_left"); - var t_str = secs_to_time(time_left); - elem.innerHTML = "<strong>" + t_str + "</strong>"; - setTimeout("update_time()", 1000); - } - else - { - document.forms["code"].submit(); - } -} - -function setSnippetHeight() -{ - var ta = document.getElementById('snippet'); - var height = ta.scrollHeight+'px'; - ta.style.height = 'auto'; - ta.style.height = height; - autoresize(); -} - -</script> -{% endblock script %} - - - -{% block onload %} onload="update_time();setSnippetHeight()" {% endblock %} - -{% block pagetitle %} - -<table><h6><div> - <tr><td class=td1-class><h5>You have {{ paper.questions_left }} question(s) left in {{ quiz_name }} </h5> - <td class=td2-class><div class=time-div id="time_left"> - </div> -</div></h6></table> - -{% endblock %} - -{% block content %} -<div class="topbar"> - <div class="fill"> - <div class="container"> - <h3 class="brand"><strong>Online Test</h3></strong> - <ul> - <li> <h5><a> Hi {{user.first_name.title}} {{user.last_name.title}} </a></h5> - </ul> - <form id="logout" action="{{URL_ROOT}}/exam/quit/{{ paper.question_paper.id }}/" method="post" class="pull-right"> - {% csrf_token %} - <button class="btn" type="submit" name="quit">Quit Exam</button> </li> - - </form> - </div> - </div> -</div> - - - <h4><u> {{ question.summary }} </u><font class=pull-right>(Marks : {{ question.points }}) </font></h4><br> - <font size=3 face=arial> {{ question.description|safe }} </font> - {% if error_message %} - <div class="alert alert-error"> - {% for e in error_message.splitlines %} - {{ e|join:"" }} - <br/> - {% endfor%} - </div>{% endif %} - - {% if success_msg %} - <script type="text/javascript"> - alert("Congratulations, that's correct. Let's go to next question"); - </script> - {% endif %} - <p id="status"></p> - <form id="code" action="{{URL_ROOT}}/exam/{{ question.id }}/check/{{ paper.question_paper.id }}/" method="post"> - {% csrf_token %} - {% if question.type == "mcq" %} - {% for option in question.options.strip.splitlines %} - <input name="answer" type="radio" value="{{option}}" />{{option}} <br/> - {% endfor %} - {% endif %} - {% if question.type == "mcc" %} - {% for option in question.options.strip.splitlines %} - <input name="answer" type="checkbox" value="{{ option }}"> {{ option }} - <br> - {% endfor %} - {% endif %} - {% if question.type == "code" %} - - <textarea rows="1" style="padding:0;height:auto;width:750px;overflow:hidden;background-color:white;border: 0 none white;" readonly="yes" name="snippet" id="snippet" wrap="off">{% if last_attempt %}{{ question.snippet }}{% else %}{% if question.type == "bash" %} #!/bin/bash {{ question.snippet }}{% else %}{{ question.snippet }}{% endif %}{% endif %}</textarea> - - <textarea tabindex=1 rows="10" style="padding:0;height:auto; box-shadow: none;width:750px;margin-bottom:10px;overflow:hidden;border:none;" name="answer" id="answer" wrap="off" onkeydown="return catchTab(this,event)">{% if last_attempt %}{{last_attempt}}{% else %}{% if question.type == "bash" %}{% else %}{% endif %}{% endif %}</textarea> -<br> - - <script type="text/javascript"> - addLineNumbers('answer'); - </script> - <script>addLineNumbers('snippet');</script> - {% endif %} - - {% if question.type == "mcq" or question.type == "mcc "%} - <br><button class="btn" type="submit" name="check" id="check">Submit Answer</button> - {% else %} - <button class="btn" type="submit" name="check" id="check" onClick="submitCode();">Check Answer</button> - {% endif %} - <button class="btn" type="submit" name="skip" id="skip">Skip Question</button> - </form> - - -{% endblock content %} diff --git a/testapp/templates/exam/quit.html b/testapp/templates/exam/quit.html deleted file mode 100644 index fee11ed..0000000 --- a/testapp/templates/exam/quit.html +++ /dev/null @@ -1,14 +0,0 @@ -{% extends "base.html" %} - -{% block title %}Quit exam {% endblock %} -{% block pagetitle %}Online Test {% endblock %} -{% block content %} - - <center><h4>Your current answers are saved.</h4></center> - <center><h4> Are you sure you wish to quit the exam?</h4></center> - <center><h4> Be sure, as you won't be able to restart this exam.</h4></center> - <form action="{{URL_ROOT}}/exam/complete/{{ id }}/" method="post"> - {% csrf_token %} - <center><button class="btn" type="submit" name="yes">Yes!</button> <button class="btn" type="button" name="no" onClick="window.location='{{ URL_ROOT }}/exam/start/{{ id }}/'">No!</button></center> - </form> -{% endblock content %} diff --git a/testapp/templates/exam/quizlist.html b/testapp/templates/exam/quizlist.html deleted file mode 100644 index 9b1fd73..0000000 --- a/testapp/templates/exam/quizlist.html +++ /dev/null @@ -1,24 +0,0 @@ -{% extends "base.html" %} - -{% block title %} Quiz List {% endblock title %} - -{% block formtitle %} Quiz List {% endblock %} - -{% block pagetitle %} Online Test {% endblock %} - -{% block content %} -{% if not quizzes and not quiz %} -<center><h5> No quizzes available. </h5></center> -{% endif %} - -{% if quizzes %} -<form method="post" action="" name='frm'> -{% csrf_token %} - -{% for quiz in quizzes %} -<a href="{{URL_ROOT}}/exam/start/{{quiz.id}}/">{{ quiz.description }}</a><br> -{% endfor %} -</form> -{% endif %} - -{% endblock %} diff --git a/testapp/templates/exam/quizzes_user.html b/testapp/templates/exam/quizzes_user.html deleted file mode 100644 index 914b6b4..0000000 --- a/testapp/templates/exam/quizzes_user.html +++ /dev/null @@ -1,81 +0,0 @@ -{% extends "user.html" %} - - -{% block subtitle %}Hello {{ user.first_name }}, welcome to your dashboard !{% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question_quiz.css" type="text/css" /> -{% endblock %} - -{% block script %} -<script src="{{ URL_ROOT }}/static/exam/js/bootstrap-alert.js"></script> -<script src="{{ URL_ROOT }}/static/exam/js/quizzes_user.js"></script> -{% endblock %} - - -{% block manage %} - {% if cannot_attempt %} - <p>You have not passed the prerequisite & hence you cannot take the quiz.</p> - {% endif %} - <h4>List of quizzes availbale for you</h4> - {% if not quizzes %} - <h5>No active quizzes for you</h5> - {% endif %} - <table> - <th>Quiz</th> - <th>Pre requisite quiz</th> - {% for paper in quizzes %} - <tr> - <td> - <a href="{{ URL_ROOT }}/exam/intro/{{paper.id}}">{{ paper.quiz.description }}</a><br> - </td> - <td> - {% if paper.quiz.prerequisite %} - You have to pass {{ paper.quiz.prerequisite.description }} for taking {{ paper.quiz.description }} - {% else %} - No pre requisites for {{ paper.quiz.description }} - {% endif %} - </td> - </tr> - {% endfor %} - </table> - <hr> - <h4>List of quizzes taken by you so far</h4> - {% if quizzes_taken %} - <table class="bordered-table zebra-striped"> - <th>Quiz</th> - <th>Result</th> - <th>Mraks Obtained</th> - <th>Total Marks</th> - <th>Percentage</th> - {% for paper in quizzes_taken %} - <tr> - <td> - {{ paper.question_paper.quiz.description }} - </td> - <td> - {% if paper.passed %} - <p>Pass</p> - {% else %} - <p>Fail</p> - {% endif %} - </td> - <td> - {{ paper.marks_obtained }} - </td> - <td> - {{ paper.question_paper.total_marks }} - </td> - <td> - {{ paper.percent }} - </td> - </tr> - {% endfor %} - </table> - {% else %} - <p>You have not taken any quiz yet !!</p> - {% endif %} - - -{% endblock %} - diff --git a/testapp/templates/exam/register.html b/testapp/templates/exam/register.html deleted file mode 100644 index 5ff79cc..0000000 --- a/testapp/templates/exam/register.html +++ /dev/null @@ -1,20 +0,0 @@ -{% extends "base.html" %} - -{% block title %}Registration form {% endblock %} - -{% block pagetitle %}Online Test {% endblock %} -{% block formtitle %}Please fill in the following details {% endblock %} - -{% block content %} - - - -<form action="" method="post"> - {% csrf_token %} - <center><table class=span1> - {{ form.as_table }} - </table></center> - <center><button class="btn" type="submit">Register</button> <button class="btn" type="reset">Cancel</button></center> -</form> - -{% endblock content %} diff --git a/testapp/templates/exam/results_user.html b/testapp/templates/exam/results_user.html deleted file mode 100644 index 2a2a309..0000000 --- a/testapp/templates/exam/results_user.html +++ /dev/null @@ -1,28 +0,0 @@ -{% extends "user.html" %} - - -{% block subtitle %}Results{% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/question_quiz.css" type="text/css" /> -{% endblock %} - -{% block manage %} -<form action="" method="post" name=frm> - {% csrf_token %} - <center><table class="span6"> - <th>Quiz Description - <th>Obtained Marks - <th>Maximum Marks - <th>Percentage - {% for paper in papers %} - <tr> - {% for i in paper %} - <td>{{ i }} - {% endfor %} - <br> - {% endfor %} - </table></center> -</form> -{% endblock %} - diff --git a/testapp/templates/exam/show_quiz.html b/testapp/templates/exam/show_quiz.html deleted file mode 100644 index cf3f552..0000000 --- a/testapp/templates/exam/show_quiz.html +++ /dev/null @@ -1,33 +0,0 @@ -{% extends "manage.html" %} - -{% block title %} Quiz List {% endblock title %} - -{% block script %} -<script src="{{ URL_ROOT }}/static/exam/js/show_quiz.js"></script> -{% endblock %} - -{% block subtitle %} Quiz List {% endblock %} -{% block manage %} -{% if not quizzes and not quiz %} -<center><h5> No quizzes available. </h5></center> -<button class="btn" type="button" onClick='location.replace("{{URL_ROOT}}/exam/manage/addquiz");'>Add New Quiz</button> -{% endif %} - -{# ############################################################### #} -{# This is rendered when we are just viewing exam/monitor #} -{% if quizzes %} -<form method="post" action="" name='frm'> -{% csrf_token %} - -{% for quiz in quizzes %} -<input type=checkbox name='quiz' value={{quiz.id}} /> <a href="{{URL_ROOT}}/exam/manage/addquiz/{{quiz.id}}/">{{ quiz.description }}</a><br> -{% endfor %} - -<br><br> -<button class="btn" type="button" onClick='location.replace("{{URL_ROOT}}/exam/manage/addquiz");'>Add New Quiz</button> -<button class="btn" type="submit" name='edit' value='edit' onClick="return confirm_edit(frm);" >Edit Selected</button> -<button class="btn" type="submit" name="delete" value='delete' onClick="return confirm_delete(frm);">Delete Selected</button> -</form> -{% endif %} - -{% endblock %} diff --git a/testapp/templates/exam/showquestionpapers.html b/testapp/templates/exam/showquestionpapers.html deleted file mode 100644 index e511472..0000000 --- a/testapp/templates/exam/showquestionpapers.html +++ /dev/null @@ -1,23 +0,0 @@ -{% extends "manage.html" %} - - -{% block subtitle %}List of Question Papers {% endblock %} - -{% block script %} -<script src="{{ URL_ROOT }}/static/exam/js/show_question.js"></script> -{% endblock %} - -{% block manage %} -{% if papers %} -<form name=frm action="" method="post"> -{% csrf_token %} -{% for i in papers %} -<input type="checkbox" name="papers" value="{{ i.id }}"> <a href="{{URL_ROOT}}/exam/manage/showquestionpapers/{{ i.id }}">{{ i.quiz.description }}</a><br> -{% endfor %} -<br> -<button class="btn" type="submit" onClick="return confirm_delete(frm);" name='delete' value='delete'>Delete Selected</button> -</form> -{% else %} -<center><h3>No Question Papers available</h3></center> -{% endif %} -{% endblock %} diff --git a/testapp/templates/exam/showquestions.html b/testapp/templates/exam/showquestions.html deleted file mode 100644 index 62b40e4..0000000 --- a/testapp/templates/exam/showquestions.html +++ /dev/null @@ -1,21 +0,0 @@ -{% extends "manage.html" %} - - -{% block subtitle %}List of Questions {% endblock %} - -{% block script %} -<script src="{{ URL_ROOT }}/static/exam/js/show_question.js"></script> -{% endblock %} - -{% block manage %} -<form name=frm action="" method="post"> -{% csrf_token %} -{% for i in questions %} -<input type="checkbox" name="question" value="{{ i.id }}"> <a href="{{URL_ROOT}}/exam/manage/addquestion/{{ i.id }}">{{ i }}</a><br> -{% endfor %} -<br> -<button class="btn" type="button" onclick='location.replace("{{URL_ROOT}}/exam/manage/addquestion/");'>Add Question</button> -<button class="btn" type="submit" name='edit' value='edit' onClick="return confirm_edit(frm);">Edit Selected</button> -<button class="btn" type="submit" onClick="return confirm_delete(frm);" name='delete' value='delete'>Delete Selected</button> -</form> -{% endblock %} diff --git a/testapp/templates/exam/showusers.html b/testapp/templates/exam/showusers.html deleted file mode 100644 index 01ecc37..0000000 --- a/testapp/templates/exam/showusers.html +++ /dev/null @@ -1,26 +0,0 @@ -{% extends "manage.html" %} - - -{% block subtitle %} -List of Users -{% endblock %} - -{% block css %} -<link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/showusers.css" type="text/css" /> -{% endblock css %} - - -{% block manage %} -<center><table style="text-align:left;" class=table-class border=3> -<th>Username -<th>First Name -<th>Last Name -<th>Quiz Description -{% for papers in question %} -<tr><td><a href="{{URL_ROOT}}/exam/manage/gradeuser/{{ papers.user.username }}">{{ papers.user.username }}</a><br> - <td >{{ papers.user.first_name.title }} - <td>{{ papers.user.last_name.title }} - <td>{{ papers.question_paper.quiz.description }} -{% endfor %} -</table></center> -{% endblock %} diff --git a/testapp/templates/exam/user_data.html b/testapp/templates/exam/user_data.html deleted file mode 100644 index 61a3a97..0000000 --- a/testapp/templates/exam/user_data.html +++ /dev/null @@ -1,80 +0,0 @@ -{% extends "manage.html" %} - -{% block title %} Data for user {{ data.user.get_full_name.title }} {% endblock title %} - -{% block manage %} - -{% block subtitle %}Data for user {{ data.user.get_full_name.title }}{% endblock %} -<form action="" method="post"> -<p> -Name: {{ data.user.get_full_name.title }} <br/> -Username: {{ data.user.username }} <br/> -{% if data.profile %} -Roll number: {{ data.profile.roll_number }} <br/> -Position: {{ data.profile.position }} <br/> -Department: {{ data.profile.department }} <br/> -Institute: {{ data.profile.institute }} <br/> -{% endif %} -Email: {{ data.user.email }} <br/> -Date joined: {{ data.user.date_joined }} <br/> -Last login: {{ data.user.last_login }} -</p> - -{% if data.papers %} -<p><a href="{{URL_ROOT}}/exam/manage/gradeuser/{{ data.user.username }}/"> - Grade/correct paper</a> -</p> - -{% for paper in data.papers %} - -<h2> Quiz: {{ paper.quiz.description }} </h2> - -<p> -Questions correctly answered: {{ paper.get_answered_str }} <br/> -Total attempts at questions: {{ paper.answers.count }} <br/> -Marks obtained: {{ paper.get_total_marks }} <br/> -Start time: {{ paper.start_time }} <br/> -User IP address: {{ paper.user_ip }} -</p> - -{% if paper.answers.count %} -<h3> Answers </h3> -{% for question, answers in paper.get_question_answers.items %} -<p><strong> Question: {{ question.id }}. {{ question.summary }} (Points: {{ question.points }})</strong> </p> -{% if question.type == "mcq" %} -<p> Choices: -{% for option in question.options.strip.splitlines %} {{option}}, {% endfor %} -</p> -<p>Student answer: {{ answers.0 }}</p> -{% else %}{# non-mcq questions #} -<pre> -{% for answer in answers %}################################################################################ -{{ answer.answer.strip }} -# Autocheck: {{ answer.error }} -{% endfor %}</pre> -{% endif %} -{% with answers|last as answer %} -<p><em>Marks: {{answer.marks}} </em> </p> -{% endwith %} -{% endfor %} {# for question, answers ... #} -<h3>Teacher comments: </h3> -{{ paper.comments|default:"None" }} -{% endif %} {# if paper.answers.count #} - -{% endfor %} {# for paper in data.papers #} - -{% endif %} {# if data.papers #} -<br /> -<hr /> -<a href="{{URL_ROOT}}/exam/manage/gradeuser/{{ data.user.username }}/"> - Grade/correct paper</a> -<br/> -{% if data.papers.count > 1 %} -<a href="{{URL_ROOT}}/exam/manage/monitor/">Monitor quiz</a> -{% else %} -{% with data.papers.0 as paper %} -<a href="{{URL_ROOT}}/exam/manage/monitor/{{paper.quiz.id}}/">Monitor quiz</a> -{% endwith %} -{% endif %} - -{% endblock %} diff --git a/testapp/templates/manage.html b/testapp/templates/manage.html deleted file mode 100644 index 1db8a78..0000000 --- a/testapp/templates/manage.html +++ /dev/null @@ -1,88 +0,0 @@ -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> - <head> - <title> - {% block title %} - {% endblock %} - </title> - - {% block meta %} -<meta charset="utf-8"> - <meta name="description" content=""> -<meta name="author" content=""> - {% endblock %} - - <link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/base.css" type="text/css" /> - <link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/manage.css" type="text/css" /> - {% block css %} - {% endblock %} - - {% block script %} - {% endblock %} - </head> - -<body {% block onload %}{% endblock %}> -<div class="topbar"> - <div class="fill"> - <div class="container"> - <a href="{{ URL_ROOT }}/exam/manage/"><h3 class="brand"><strong>Online Test</h3></strong></a> -<ul> -<li><a href="{{ URL_ROOT }}/exam/manage/questions">Questions</a></li> - <li><a href="{{ URL_ROOT }}/exam/manage/showquiz">Quizzes</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> - </ul> -<ul style="float:right;"> -<li><strong><a style='cursor:pointer' onClick='location.replace("{{URL_ROOT}}/exam/complete/");'>Log out</a></strong></li> - </ul> - </div> - </div> -</div> - <div class="container"> - <div class="content"> - <div class="page-header"> -<h3><center>{% block subtitle %}Welcome {{ user.first_name.title }} {{user.last_name.title}} !{% endblock %}</center></h3><br> - </div> - <div class=row> - <div class=span14> - {% block manage %} - <center><h4>List of quizzes! Click on the given links to have a look at answer papers for a quiz.</h4></center> - <hr> - <table class="bordered-table zebra-striped"> - <th>Quiz</th> - <th>Taken By</th> - <th>No. of users Passed</th> - <th>No. of users Failed</th> - {% for paper, answer_papers, users_passed, users_failed in users_per_paper %} - <tr> - <td> - <a href="{{URL_ROOT}}/exam/manage/monitor/{{paper.id}}/">{{ paper.quiz.description }}</a> - </td> - <td> - {{ answer_papers|length }} user(s) - </td> - <td> - {{ users_passed }} - </td> - <td> - {{ users_failed }} - </td> - </tr> - {% endfor %} - </table> - <hr> - <center> - <h4>Moderator's Dashboard!</h4> - <h5>Click on the button given below to add a new quiz.</h5> - <button class="btn" type="button" onClick='location.replace("{{URL_ROOT}}/exam/manage/addquiz");'>Add New Quiz</button> - </center> -{% endblock %} - </div> - </div> - </div> - <footer> - <p>© FOSSEE group, IIT Bombay</p> - </footer> - </div> - -</body> -</html> diff --git a/testapp/templates/user.html b/testapp/templates/user.html deleted file mode 100644 index 22a9fac..0000000 --- a/testapp/templates/user.html +++ /dev/null @@ -1,58 +0,0 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" -"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> - -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> - <head> - <title> - {% block title %} - {% endblock %} - </title> - - {% block meta %} - <meta charset="utf-8"> - <meta name="description" content=""> - <meta name="author" content=""> - {% endblock %} - - <link rel="stylesheet" href="{{ URL_ROOT }}/static/exam/css/base.css" type="text/css" /> - {% block css %} - {% endblock %} - - {% block script %} - {% endblock %} - </head> - -<body {% block onload %}{% endblock %}> -<div class="topbar"> - <div class="fill"> - <div class="container"> - <h3 class="brand"><strong>Online Test</h3></strong> - <ul> - <li><a href="{{ URL_ROOT }}/exam/quizzes">Quizzes</a></li> - <li><a href="{{ URL_ROOT }}/exam/results">Results</a></li> - </ul> - <ul style="float:right;"> - <li><strong><a style='cursor:pointer' onClick='location.replace("{{URL_ROOT}}/exam/complete/");'>Log out</a></strong></li> - </ul> - </div> - </div> -</div> - <div class="container"> - <div class="content"> - <div class="page-header"> - <h3><center>{% block subtitle %}Welcome {{ user.first_name.title }} {{user.last_name.title}} {% endblock %}</center></h3><br> - </div> - <div class=row> - <div class=span14> - {% block manage %} - {% endblock %} - </div> - </div> - </div> - <footer> - <p>© FOSSEE group, IIT Bombay</p> - </footer> - </div> - -</body> -</html> |