Search form and pagination
This commit is contained in:
@@ -30,6 +30,14 @@
|
||||
<th>Weight Category:</th><td>{{ workout.weightcategory }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
<form id="searchform" action="."
|
||||
method="get" accept-charset="utf-8">
|
||||
<button class="button blue small" type="submit">
|
||||
Search
|
||||
</button>
|
||||
<input class="searchfield" id="searchbox" name="q" type="text" placeholder="Search">
|
||||
</form>
|
||||
|
||||
</div>
|
||||
|
||||
<div id="comparison" class="grid_8 omega">
|
||||
@@ -73,5 +81,21 @@
|
||||
{% else %}
|
||||
<p> No workouts found </p>
|
||||
{% endif %}
|
||||
|
||||
<div class="grid_2 prefix_5 suffix_1 omega">
|
||||
<span class="button gray small">
|
||||
{% if workouts.has_previous %}
|
||||
<a class="wh" href="?page={{ workouts.previous_page_number }}"><</a>
|
||||
{% endif %}
|
||||
|
||||
<span>
|
||||
Page {{ workouts.number }} of {{ workouts.paginator.num_pages }}.
|
||||
</span>
|
||||
|
||||
{% if workouts.has_next %}
|
||||
<a class="wh" href="?page={{ workouts.next_page_number }}">></a>
|
||||
{% endif %}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
@@ -6,6 +6,14 @@
|
||||
|
||||
{% block content %}
|
||||
<h1>Recent Graphs</h1>
|
||||
|
||||
<form id="searchform" action="."
|
||||
method="get" accept-charset="utf-8">
|
||||
<button class="button blue small" type="submit">
|
||||
Search
|
||||
</button>
|
||||
<input class="searchfield" id="searchbox" name="q" type="text" placeholder="Search">
|
||||
</form>
|
||||
{% if graphs1 %}
|
||||
<div class="grid_1 alpha">
|
||||
<p> </p>
|
||||
|
||||
@@ -5,8 +5,10 @@
|
||||
{% block title %}Workouts{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="grid_12">
|
||||
<h1>My Workouts</h1>
|
||||
{% if workouts %}
|
||||
|
||||
{% if workouts %}
|
||||
<table width="70%" class="listtable">
|
||||
<thead>
|
||||
<tr>
|
||||
@@ -49,4 +51,35 @@
|
||||
{% else %}
|
||||
<p> No workouts found </p>
|
||||
{% endif %}
|
||||
</div>
|
||||
<div class="grid_6 alpha">
|
||||
<form id="searchform" action="."
|
||||
method="get" accept-charset="utf-8">
|
||||
<div class="grid_3 alpha">
|
||||
<input class="searchfield" id="searchbox" name="q" type="text" placeholder="Search">
|
||||
</div>
|
||||
<div class="grid_1 suffix_2 omega">
|
||||
<button class="button blue small" type="submit">
|
||||
Search
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div class="grid_2 prefix_4 omega">
|
||||
<span class="button gray small">
|
||||
{% if workouts.has_previous %}
|
||||
<a class="wh" href="?page={{ workouts.previous_page_number }}"><</a>
|
||||
{% endif %}
|
||||
|
||||
<span>
|
||||
Page {{ workouts.number }} of {{ workouts.paginator.num_pages }}.
|
||||
</span>
|
||||
|
||||
{% if workouts.has_next %}
|
||||
<a class="wh" href="?page={{ workouts.next_page_number }}">></a>
|
||||
{% endif %}
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user