-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
155 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
<table> | ||
|
||
{% for fid,filter in filters %} | ||
<tr class="tabulate-filter"> | ||
<td class="label"> | ||
<label> | ||
{% if fid==0 %}Find records where{% else %}…and{% endif %} | ||
</label> | ||
</td> | ||
<td> | ||
<select name="filter[{{fid}}][column]" class="form-control"> | ||
{% for column in table.get_columns %} | ||
<option value="{{column.get_name}}" {% if column.get_name==filter.column %}selected{% endif %}> | ||
{{column.get_title}} | ||
</option> | ||
{% endfor %} | ||
</select> | ||
</td> | ||
<td> | ||
<select name="filter[{{fid}}][operator]" class="form-control"> | ||
{% for op,name in table.get_operators %} | ||
<option value="{{op}}" {% if op==filter.operator %}selected{% endif %}> | ||
{{name}} | ||
</option> | ||
{% endfor %} | ||
</select> | ||
</td> | ||
<td> | ||
{% if filter.operator == 'in' or filter.operator == 'not in' %} | ||
<textarea name="filter[{{fid}}][value]" class="form-control">{{filter.value}}</textarea> | ||
{% else %} | ||
<input type="text" name="filter[{{fid}}][value]" value="{{filter.value}}" class="form-control" /> | ||
{% endif %} | ||
</td> | ||
</tr> | ||
{% endfor %} | ||
|
||
<tr> | ||
<td colspan="3"> | ||
</td> | ||
<td class="buttons"> | ||
<button class="button btn btn-success" data-controller="table" data-action="index">Search</button> | ||
{% if table.get_filters > 1 %} | ||
<a href="{{clear_url}}" class="button btn btn-default">Clear filters</a> | ||
{% endif %} | ||
</td> | ||
</tr> | ||
|
||
</table> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
<form action="{{form_action}}" method="get" class="tabulate-filters about-description"> | ||
<input type="hidden" name="table" value="{{table.get_name}}" /> | ||
|
||
{% if search %} | ||
{% include "filters.html" with {clear_url:form_action} %} | ||
{% endif %} | ||
|
||
<p class="tabulate paginate"> | ||
<span class="displaying-num"> | ||
{{table.count_records|number_format}} record{% if record_count != 1 %}s{% endif %} | ||
</span> | ||
|
||
{% if table.get_page_count > 1 %} | ||
<span class='pagination-links'> | ||
<button class='first-page {%if table.get_current_page_num == 1%}disabled{% endif %} button' title='Go to the first page' | ||
data-p="1" > | ||
« | ||
</button> | ||
<button class='prev-page {%if table.get_current_page_num == 1%}disabled{% endif %} button' title='Go to the previous page' | ||
data-p="{{(table.get_current_page_num - 1)}}"> | ||
‹ | ||
</button> | ||
<span class="paging-input"> | ||
<input class='current-page' id='current-page-selector' title='Current page' | ||
type='text' name='tabulate_p' value='{{table.get_current_page_num}}' size='1' /> | ||
of | ||
<span class='total-pages'>{{table.get_page_count|number_format}}</span> pages | ||
</span> | ||
<button class='next-page {%if table.get_current_page_num == table.get_page_count%}disabled{% endif %} button' | ||
data-p="{{(table.get_current_page_num + 1)}}" title='Go to the next page'> | ||
› | ||
</button> | ||
<button class='last-page {%if table.get_current_page_num == table.get_page_count%}disabled{% endif %} button' | ||
data-p="{{table.get_page_count}}" title='Go to the last page'> | ||
» | ||
</button> | ||
</span> | ||
{% endif %} | ||
|
||
</p><!-- .tabulate.paginate --> | ||
|
||
</form> | ||
|
||
{% include 'data_table.html' with { links:false } %} |