summaryrefslogtreecommitdiff
path: root/static
diff options
context:
space:
mode:
authorashwinishinde2015-03-23 11:31:45 +0530
committerashwinishinde2015-03-23 11:31:45 +0530
commit801a325c85ba2c9ac6b12de55fbe7f01b8c5c416 (patch)
tree57d7e243850ad89d114f65f8bf171e5833c37943 /static
parente13bc6c1ea96e664f138831a0251c74cccd62fb2 (diff)
downloadFOSSEE-Forum-801a325c85ba2c9ac6b12de55fbe7f01b8c5c416.tar.gz
FOSSEE-Forum-801a325c85ba2c9ac6b12de55fbe7f01b8c5c416.tar.bz2
FOSSEE-Forum-801a325c85ba2c9ac6b12de55fbe7f01b8c5c416.zip
Subject: validate submit answer for balnk field.
Description: 1) body in answering the question should not be blank. 2) removed search icon and linkfy questions and category.
Diffstat (limited to 'static')
-rw-r--r--static/website/templates/filter.html12
-rw-r--r--static/website/templates/get-question.html5
-rw-r--r--static/website/templates/index.html4
3 files changed, 10 insertions, 11 deletions
diff --git a/static/website/templates/filter.html b/static/website/templates/filter.html
index eb42fcb..c444e78 100644
--- a/static/website/templates/filter.html
+++ b/static/website/templates/filter.html
@@ -36,16 +36,14 @@
{% for question in questions %}
<tr {% if question.id == qid %}class="parent-filter"{% endif %}>
<td>
- <span href="#" class="category" data-toggle="tooltip" data-placement="top" title="{{ question.category}}">
- {{ question.category|truncatechars:12 }}
- </span>
- <a class="pull-right" href="{% url 'website:filter' question.category %}?qid={{ question.id }}">
- <span class="glyphicon glyphicon-search"></span>
- </a>
+ <span class="category" data-toggle="tooltip" data-placement="top" title="{{ question.category}}">
+ <a class="pull-left" href="{% url 'website:filter' question.category %}?qid={{ question.id }}">
+ {{ question.category|truncatechars:12 }} </a>
+ </span>
</td>
<td>
- <span class="title" data-toggle="tooltip" data-placement="top" title="{{ question.title }}">
+ <span class="question" data-toggle="tooltip" data-placement="top" title="{{ question.title }}">
<a href="{% url 'website:get_question' question.id %}{% prettify question.title %}">{{ question.title|truncatechars:40 }}</a>
</span>
</td>
diff --git a/static/website/templates/get-question.html b/static/website/templates/get-question.html
index 18758c9..3a0e4eb 100644
--- a/static/website/templates/get-question.html
+++ b/static/website/templates/get-question.html
@@ -164,15 +164,16 @@
{% endfor %}
{% if user.is_authenticated %}
- <form action="{% url 'website:question_answer' %}" method="POST"> {% csrf_token %}
+ <form action="{% url 'website:question_answer' question.id %}" method="POST"> {% csrf_token %}
{% with WIDGET_ERROR_CLASS='field_error' %}
<div class="row">
<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12">
<div class="form-group">
{% render_field form.question value=question.id %}
<label for="id_body">Answer</label>
- {% render_field form.body class+='form-control' %}
+ {% render_field form.body class+='form-control body' %}
</div>
+ {{ form.body.errors }}
</div>
</div>
{% endwith %}
diff --git a/static/website/templates/index.html b/static/website/templates/index.html
index 48f0227..fa076b9 100644
--- a/static/website/templates/index.html
+++ b/static/website/templates/index.html
@@ -59,9 +59,9 @@
</div>
<div class="panel-body">
<table class="table table-bordered table-hover">
- <th> FOSS <span class="glyphicon glyphicon-link"></span></th>
+ <th> FOSS </th>
<!--<th> Tutorial</th>-->
- <th> Question <span class="glyphicon glyphicon-link"></span></th>
+ <th> Question </th>
<th> Date</th>
<th> Views</th>
<th> Answers</th>