diff options
author | Jayaram Pai | 2013-12-22 22:50:27 +0530 |
---|---|---|
committer | Jayaram Pai | 2013-12-22 22:50:27 +0530 |
commit | 1541ab6a4ff28a6a0a4e37873367314e3b898dac (patch) | |
tree | 80c62ab7fb280e1db5afa85fb20c72dbf97d9cc1 /static/website/templates/index.html | |
parent | a5279e062d09ef8b0fcfe9354d41d7e01d29ae69 (diff) | |
download | FOSSEE-Forum-1541ab6a4ff28a6a0a4e37873367314e3b898dac.tar.gz FOSSEE-Forum-1541ab6a4ff28a6a0a4e37873367314e3b898dac.tar.bz2 FOSSEE-Forum-1541ab6a4ff28a6a0a4e37873367314e3b898dac.zip |
making forum in table format
Diffstat (limited to 'static/website/templates/index.html')
-rw-r--r-- | static/website/templates/index.html | 105 |
1 files changed, 64 insertions, 41 deletions
diff --git a/static/website/templates/index.html b/static/website/templates/index.html index ef840bc..cb5f3df 100644 --- a/static/website/templates/index.html +++ b/static/website/templates/index.html @@ -2,58 +2,75 @@ {% block content %} {% load count_tags %} <h4><u>Recent Questions</u></h4> +<table class="table table-striped table-bordered table-hover"> + <th> FOSS </th> + <th>TUTORIAL</th> + <th> MIN</th> + <th> SEC </th> + <th> QUESTION</th> + <th> DATE</th> + <th>VIEWS</th> + <th> USER</th> {% for question in questions %} - <div class="question"> - <div class="title"> - <a href="{% url 'website:get_question' question.id %}">{{ question.title }}</a> - </div> - <br> - <span class="category"> - <small> - <a href="{% url 'website:filter' question.category %}?qid={{ question.id }}"> - {{ question.category }} - </a> - </small> + <tr> + <td> + <span href="#" class="category" data-toggle="tooltip" data-placement="top" title="{{ question.category}}"> + {{ question.category|truncatechars:15 }} </span> + <a class="pull-right" href="{% url 'website:filter' question.category %}?qid={{ question.id }}"> + <span class="glyphicon glyphicon-search"></span> + </a> + </td> - <span class="tutorial"> - <small> - <a href="{% url 'website:filter' question.category question.tutorial %}?qid={{ question.id }}"> - {{ question.tutorial}} - </a> - </small> + <td> + <span class="tutorial" data-toggle="tooltip" data-placement="top" title="{{ question.tutorial}}"> + {{ question.tutorial|truncatechars:15 }} </span> + <a class="pull-right" href="{% url 'website:filter' question.category question.tutorial %}?qid={{ question.id }}"> + <span class="glyphicon glyphicon-search"></span> + </a> + </td> - <span class="minute_range"> - <small> - <a href="{% url 'website:filter' question.category question.tutorial question.minute_range %}?qid={{ question.id }}"> - {{ question.minute_range }} min - </a> - </small> + <td> + <span> + <a href="{% url 'website:filter' question.category question.tutorial question.minute_range %}?qid={{ question.id }}"> + {{ question.minute_range }} + </a> </span> + </td> - <span class="second_range"> - <small> - <a href="{% url 'website:filter' question.category question.tutorial question.minute_range question.second_range%}?qid={{ question.id }}"> - {{ question.second_range }} sec - </a> - </small> + <td> + <span> + <a href="{% url 'website:filter' question.category question.tutorial question.minute_range question.second_range%}?qid={{ question.id }}"> + {{ question.second_range }} + </a> </span> - - <span class="meta"> - <small> - <i> - {{ question.date_created }} - </i> - </small> + </td> + + <td> + <span class="title" data-toggle="tooltip" data-placement="top" title="{{ question.title }}"> + <a href="{% url 'website:get_question' question.id %}">{{ question.title|truncatechars:45 }}</a> + </span> + </td> - <span class="user"> - {{ question.user }} - </span> + <td> + <span> + <i> + {{ question.date_created|date:"y-d-m" }} + </i> </span> - </div> <!-- /.question --> - {% endfor %} + </td> + <td> + {{ question.views}} + </td> + + <td> + {{ question.user }} + </td> + </tr> + {% endfor %} +</table> {% if total > 10 %} <ul class="pagination pull-right"> {% for i in total|get_range:"0,10" %} @@ -71,3 +88,9 @@ {% endif %} {% endblock %} + +{% block javascript %} +<script> + $('span').tooltip(); +</script> +{% endblock %} |