summaryrefslogtreecommitdiff
path: root/testapp
diff options
context:
space:
mode:
authorhardythe12012-03-20 12:44:43 +0530
committerhardythe12012-03-20 12:44:43 +0530
commite524bef336df95fd307d045af37c379bccf3ea14 (patch)
tree62b677d6c94f323f880d77745e57a25e844b4ba9 /testapp
parent0e6e72fb37f1a586728c997cd5e9c5fadf794823 (diff)
downloadonline_test-e524bef336df95fd307d045af37c379bccf3ea14.tar.gz
online_test-e524bef336df95fd307d045af37c379bccf3ea14.tar.bz2
online_test-e524bef336df95fd307d045af37c379bccf3ea14.zip
minor UI changes
Diffstat (limited to 'testapp')
-rw-r--r--testapp/static/exam/css/base.css63
-rw-r--r--testapp/static/exam/css/gradeuser.css5
-rw-r--r--testapp/static/exam/css/question.css2
-rw-r--r--testapp/templates/exam/add_question.html1
-rw-r--r--testapp/templates/exam/add_quiz.html3
-rw-r--r--testapp/templates/exam/edit_question.html18
-rw-r--r--testapp/templates/exam/edit_quiz.html18
-rw-r--r--testapp/templates/exam/question.html6
8 files changed, 86 insertions, 30 deletions
diff --git a/testapp/static/exam/css/base.css b/testapp/static/exam/css/base.css
index 80f52d7..e1adc48 100644
--- a/testapp/static/exam/css/base.css
+++ b/testapp/static/exam/css/base.css
@@ -176,7 +176,7 @@ input[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
textarea {
- overflow: auto;
+ overflow: visible;
vertical-align: top;
}
/* Variables.less
@@ -515,7 +515,7 @@ dl dd {
hr {
margin: 20px 0 19px;
border: 0;
- border-bottom: 3px solid;
+ border-bottom: 1px solid;
}
strong {
font-style: inherit;
@@ -564,12 +564,13 @@ code, pre {
border-radius: 3px;
}
code {
- background-color: #fee9cc;
+ background-color: #FDE8E8;
color: rgba(0, 0, 0, 0.75);
padding: 1px 3px;
}
pre {
- background-color: #f5f5f5;
+ background-color: #EAB9B9;
+ color:red;
display: block;
padding: 8.5px;
margin: 0 0 18px;
@@ -1839,6 +1840,60 @@ footer {
:root .alert-message, :root .btn {
border-radius: 0 \0;
}
+.alert {
+ padding: 8px 35px 8px 14px;
+ margin-bottom: 18px;
+ text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
+ background-color: #fcf8e3;
+ border: 1px solid #fbeed5;
+ -webkit-border-radius: 4px;
+ -moz-border-radius: 4px;
+ border-radius: 4px;
+}
+.alert, .alert-heading {
+ color: #c09853;
+}
+.alert .close {
+ position: relative;
+ top: -2px;
+ right: -21px;
+ line-height: 18px;
+}
+.alert-success {
+ background-color: #dff0d8;
+ border-color: #d6e9c6;
+}
+.alert-success, .alert-success .alert-heading {
+ color: #468847;
+}
+.alert-danger, .alert-error {
+ background-color: #f2dede;
+ border-color: #eed3d7;
+}
+.alert-danger,
+.alert-error,
+.alert-danger .alert-heading,
+.alert-error .alert-heading {
+ color: #b94a48;
+}
+.alert-info {
+ background-color: #d9edf7;
+ border-color: #bce8f1;
+}
+.alert-info, .alert-info .alert-heading {
+ color: #3a87ad;
+}
+.alert-block {
+ padding-top: 14px;
+ padding-bottom: 14px;
+}
+.alert-block > p, .alert-block > ul {
+ margin-bottom: 0;
+}
+.alert-block p + p {
+ margin-top: 5px;
+}
+
button.btn::-moz-focus-inner, input[type=submit].btn::-moz-focus-inner {
padding: 0;
border: 0;
diff --git a/testapp/static/exam/css/gradeuser.css b/testapp/static/exam/css/gradeuser.css
index 2042f85..07b1079 100644
--- a/testapp/static/exam/css/gradeuser.css
+++ b/testapp/static/exam/css/gradeuser.css
@@ -6,7 +6,7 @@ height : 200px;
}
.for-question{
- background: none repeat scroll 0 0 #F1F1F1;
+ background: none repeat scroll 0 0 #F1F1F1;
border-radius: 6px 6px 6px 6px;
margin-bottom: 10px;
padding: 5px;
@@ -36,10 +36,13 @@ color: #9EB6FF;
border: 1px solid #C9C9C9;
border-radius: 5px 5px 5px 5px;
margin-bottom: 10px;
+ min-width: 805px;
+
}
#myContent {
margin: 5px 10px;
+
}
#headerDiv a {
float: right;
diff --git a/testapp/static/exam/css/question.css b/testapp/static/exam/css/question.css
index 3fd0c3c..a57b6dd 100644
--- a/testapp/static/exam/css/question.css
+++ b/testapp/static/exam/css/question.css
@@ -2,7 +2,7 @@
{
background-color:black;
padding: 8px;
- color: white;
+ color: #5DFC0A;
vertical-align:middle;
width:150px;
float:right;
diff --git a/testapp/templates/exam/add_question.html b/testapp/templates/exam/add_question.html
index 6c1d533..f832d46 100644
--- a/testapp/templates/exam/add_question.html
+++ b/testapp/templates/exam/add_question.html
@@ -11,6 +11,7 @@
<script type="text/javascript" src="{{ URL_ROOT }}/static/exam/css/min.js"></script>
<script type="text/javascript">
+
function increase(frm)
{
if(frm.points.value == "")
diff --git a/testapp/templates/exam/add_quiz.html b/testapp/templates/exam/add_quiz.html
index fe99ce6..570b3c2 100644
--- a/testapp/templates/exam/add_quiz.html
+++ b/testapp/templates/exam/add_quiz.html
@@ -25,7 +25,6 @@
</table>
</center>
<center><button class="btn" type="submit" name="save">Save</button>
- <button class="btn" type="button" name="button" onClick="javascript:test()">Cancel</button> </center>
- <!--button class="btn" type="button" name="button" onClick='location.replace("{{URL_ROOT}}/exam/manage/showquiz/");'>Cancel</button> </center-->
+ <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/edit_question.html b/testapp/templates/exam/edit_question.html
index 2ab3c7a..9d92a71 100644
--- a/testapp/templates/exam/edit_question.html
+++ b/testapp/templates/exam/edit_question.html
@@ -58,7 +58,6 @@ function data(showContent,showHideDiv,a,summary)
{
con.style.display = "block";
ele.style.display = "block";
- atag.text = "Hide";
}
}
@@ -179,30 +178,31 @@ function autosubmit()
{% 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 cellspacing=2px><td><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>
+ <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>Summary: <td>{{ form.summary }}{{ form.summary.errors }}
+ <tr><td><b>Summary:</b> <td>{{ form.summary }}{{ form.summary.errors }}
- <tr><td>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 }} &nbsp; Active: &nbsp; {{ form.active }}{{form.active.errors}} &nbsp; Type: &nbsp;{{ 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 }} &nbsp; Active: &nbsp; {{ form.active }}{{form.active.errors}} &nbsp; Type: &nbsp;{{ form.type }}{{form.type.errors}}
<tr><td><strong>Rendered: </strong><td><p id='my{{forloop.counter}}'></p>
- <tr><td>Description: <td>{{ form.description }} {{form.description.errors}}
- <tr><td>Test: <td>{{ form.test }}{{form.test.errors}}
- <tr><td id='label_option{{forloop.counter}}'>Options: <td>{{ form.options }} {{form.options.errors}} {{form.options.helptext}}
+ <tr><td><b>Description: <td>{{ form.description }} {{form.description.errors}}
+ <tr><td><b>Test: <td>{{ form.test }}{{form.test.errors}}
+ <tr><td id='label_option{{forloop.counter}}'><b>Options: <td>{{ form.options }} {{form.options.errors}} {{form.options.helptext}}
</table></center>
</div>
</div>
- <tr><td><hr>
{% endfor %}
-</table>
+</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>
diff --git a/testapp/templates/exam/edit_quiz.html b/testapp/templates/exam/edit_quiz.html
index d513e7a..2ab01bb 100644
--- a/testapp/templates/exam/edit_quiz.html
+++ b/testapp/templates/exam/edit_quiz.html
@@ -8,7 +8,7 @@
<style type='text/css'>
table th, table td
{
- text-align: center;
+ text-align: left;
}
</style>
{% endblock %}
@@ -17,15 +17,13 @@ table th, table td
<form name=frm action="{{URL_ROOT}}/exam/manage/editquiz/" method="post">
{% csrf_token %}
<center>
- <table>
- <tr>
- <td><strong> Start Date <td><strong> Duration <td> <strong>Active <td> <strong>Description </strong>
- </tr>
- {% for form in forms %}
-
- <tr>
- <td> {{ form.start_date}} <td> {{ form.duration }} <td> {{ form.active }} <td> {{ form.description }}
- </tr>
+ <table class=span1>
+ {% for form in forms %}
+ <tr><td><b>Start Date: <td>{{ form.start_date}}
+ <tr><td><b>Duration: <td> {{ form.duration }}
+ <tr><td><b>Active: <td> {{ form.active }}
+ <tr><td><b>Description: <td> {{ form.description }}
+ <hr>
{% endfor %}
</table>
</center>
diff --git a/testapp/templates/exam/question.html b/testapp/templates/exam/question.html
index a09e3bf..b4b171e 100644
--- a/testapp/templates/exam/question.html
+++ b/testapp/templates/exam/question.html
@@ -68,7 +68,7 @@
<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>
+ <li> <h5><a> Hi {{user.first_name.title}} {{user.last_name.title}} </a></h5>
</ul>
<form id="logout" action="{{URL_ROOT}}/exam/quit/" method="post" class="pull-right">
{% csrf_token %}
@@ -83,7 +83,7 @@
<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 %}<h5>ERROR:<h5><pre>{{ error_message }}</pre>{% endif %}
+ {% if error_message %}<h5>ERROR:</h5><div class="alert alert-error">{{ error_message }}</div>{% endif %}
<p id="status"></p>
<form id="code" action="{{URL_ROOT}}/exam/{{ question.id }}/check/" method="post">
{% csrf_token %}
@@ -92,7 +92,7 @@
<input name="answer" type="radio" value="{{option}}" />{{option}} <br/>
{% endfor %}
{% else %}
- <textarea rows="15" style="width:700px;" name="answer">{% if last_attempt %}{{last_attempt.strip}}{% else %}{% if question.type == "bash" %} #!/bin/bash{% else %}# Enter your answer here.{% endif %}{% endif %}</textarea>
+ <textarea rows="15" style="width:810px;margin-bottom:10px;" name="answer">{% if last_attempt %}{{last_attempt.strip}}{% else %}{% if question.type == "bash" %} #!/bin/bash{% else %}# Enter your answer here.{% endif %}{% endif %}</textarea>
{% endif %}
{% if question.type == "mcq" %}