diff options
author | mahesh | 2017-04-21 03:12:10 +0530 |
---|---|---|
committer | mahesh | 2017-06-14 12:45:07 +0530 |
commit | a37b9b082ef9c89bd8f06844afad5db691e25995 (patch) | |
tree | 35e651edc10f1f3a3572f088ed67d6cb068b9572 /yaksh/templates | |
parent | ebc8a2af6d4fdf52a9703701a97a3abfaf66ed06 (diff) | |
download | online_test-a37b9b082ef9c89bd8f06844afad5db691e25995.tar.gz online_test-a37b9b082ef9c89bd8f06844afad5db691e25995.tar.bz2 online_test-a37b9b082ef9c89bd8f06844afad5db691e25995.zip |
added search tag feature in showquestions
Diffstat (limited to 'yaksh/templates')
-rw-r--r-- | yaksh/templates/yaksh/showquestions.html | 29 |
1 files changed, 25 insertions, 4 deletions
diff --git a/yaksh/templates/yaksh/showquestions.html b/yaksh/templates/yaksh/showquestions.html index a136ddf..6e1ea6e 100644 --- a/yaksh/templates/yaksh/showquestions.html +++ b/yaksh/templates/yaksh/showquestions.html @@ -26,9 +26,9 @@ Upload File <span class="glyphicon glyphicon-open"></span></button> {% endif %} <br><br> <form name=frm action="" method="post"> -{% csrf_token %} +<!-- Filtering Questions --> <div class="row" id="selectors"> - <h5 style="padding-left: 20px;">Filters</h5> + <h4 style="padding-left: 20px;">Filters Questions: </h4> <div class="col-md-3"> {{ form.question_type }} </div> @@ -40,16 +40,37 @@ Upload File <span class="glyphicon glyphicon-open"></span></button> </div> </div> <br> - <button class="btn btn-primary" type="button" onClick='location.replace("{{URL_ROOT}}");'>Clear Filters</button> -<br> + <button class="btn btn-primary" type="button" onClick='location.replace("{{URL_ROOT}}");'> + Clear Filters</button> +<br><br> +<!-- Searching Tags --> +{% csrf_token %} + <div class="col-md-16"> + <div class="input-group"> + <span class="input-group-addon" id="basic-addon1">Search Questions </span> + <input type="text" name="question_tags" class="form-control" + placeholder="Search using comma separated Tags"> + <span class="input-group-btn"> + <button class="btn btn-default" type="submit">Search</button> + <button class="btn btn-default" onclick='location.replace("{{URL_ROOT}}/exam/manage/questions/");'> + Cancel</button> + </span> + </div> + </div> <div id="filtered-questions"> +{% if not search_result %} {% if questions %} <h5><input id="checkall" type="checkbox"> Select All </h5> {% 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 %} {% endif %} +{% else %} +{% for i in search_result %} +<input type="checkbox" name="question" value="{{ i.id }}"> <a href="{{URL_ROOT}}/exam/manage/addquestion/{{ i.id }}">{{ i }}</a><br> +{% endfor %} +{% endif %} </div> <br> <button class="btn btn-primary" type="button" onclick='location.replace("{{URL_ROOT}}/exam/manage/addquestion/");'>Add Question <span class="glyphicon glyphicon-plus"></span></button> |