diff options
author | Tudor Florea <tudor.florea@enea.com> | 2014-10-16 03:05:19 +0200 |
---|---|---|
committer | Tudor Florea <tudor.florea@enea.com> | 2014-10-16 03:05:19 +0200 |
commit | c527fd1f14c27855a37f2e8ac5346ce8d940ced2 (patch) | |
tree | bb002c1fdf011c41dbd2f0927bed23ecb5f83c97 /bitbake/lib/toaster/bldviewer/templates/simple_basetable.html | |
download | poky-daisy-140929.tar.gz |
initial commit for Enea Linux 4.0-140929daisy-140929
Migrated from the internal git server on the daisy-enea-point-release branch
Signed-off-by: Tudor Florea <tudor.florea@enea.com>
Diffstat (limited to 'bitbake/lib/toaster/bldviewer/templates/simple_basetable.html')
-rw-r--r-- | bitbake/lib/toaster/bldviewer/templates/simple_basetable.html | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/bitbake/lib/toaster/bldviewer/templates/simple_basetable.html b/bitbake/lib/toaster/bldviewer/templates/simple_basetable.html new file mode 100644 index 0000000000..762d78629c --- /dev/null +++ b/bitbake/lib/toaster/bldviewer/templates/simple_basetable.html | |||
@@ -0,0 +1,64 @@ | |||
1 | {% extends "simple_base.html" %} | ||
2 | |||
3 | {% block pagecontent %} | ||
4 | <script> | ||
5 | function showhideTableColumn(i, sh) { | ||
6 | if (sh) | ||
7 | $('td:nth-child('+i+'),th:nth-child('+i+')').show(); | ||
8 | else | ||
9 | $('td:nth-child('+i+'),th:nth-child('+i+')').hide(); | ||
10 | } | ||
11 | |||
12 | |||
13 | function filterTableRows(test) { | ||
14 | if (test.length > 0) { | ||
15 | var r = test.split(/[ ,]+/).map(function (e) { return new RegExp(e, 'i') }); | ||
16 | $('tr.data').map( function (i, el) { | ||
17 | (! r.map(function (j) { return j.test($(el).html())}).reduce(function (c, p) { return c && p;} )) ? $(el).hide() : $(el).show(); | ||
18 | }); | ||
19 | } else | ||
20 | { | ||
21 | $('tr.data').show(); | ||
22 | } | ||
23 | } | ||
24 | </script> | ||
25 | <div style="margin-bottom: 0.5em"> | ||
26 | |||
27 | {% block pagename %} | ||
28 | {% endblock %} | ||
29 | <div align="left" style="display:inline-block; width: 40%; margin-left: 2em"> Filter: <input type="search" id="filterstring" style="width: 80%" onkeyup="filterTableRows($('#filterstring').val())" autocomplete="off"> | ||
30 | </div> | ||
31 | {% if hideshowcols %} | ||
32 | <div align="right" style="display: inline-block; width: 40%">Show/Hide columns: | ||
33 | {% for i in hideshowcols %} | ||
34 | <span>{{i.name}} <input type="checkbox" id="ct{{i.name}}" onchange="showhideTableColumn({{i.order}}, $('#ct{{i.name}}').is(':checked'))" checked autocomplete="off"></span> | | ||
35 | {% endfor %} | ||
36 | </div> | ||
37 | {% endif %} | ||
38 | </div> | ||
39 | |||
40 | <div style="display: block; float:right; margin-left: auto; margin-right:5em"><span class="pagination" style="vertical-align: top; margin-right: 3em">Showing {{objects.start_index}} to {{objects.end_index}} out of {{objects.paginator.count}} entries. </span> | ||
41 | <ul class="pagination" style="display: block-inline"> | ||
42 | {%if objects.has_previous %} | ||
43 | <li><a href="?page={{objects.previous_page_number}}">«</a></li> | ||
44 | {%else%} | ||
45 | <li class="disabled"><a href="#">«</a></li> | ||
46 | {%endif%} | ||
47 | {% for i in objects.page_range %} | ||
48 | <li{%if i == objects.number %} class="active" {%endif%}><a href="?page={{i}}">{{i}}</a></li> | ||
49 | {% endfor %} | ||
50 | {%if objects.has_next%} | ||
51 | <li><a href="?page={{objects.next_page_number}}">»</a></li> | ||
52 | {%else%} | ||
53 | <li class="disabled"><a href="#">»</a></li> | ||
54 | {%endif%} | ||
55 | </ul> | ||
56 | </div> | ||
57 | |||
58 | <table class="table table-striped table-condensed" style="width:95%"> | ||
59 | {% block pagetable %} | ||
60 | {% endblock %} | ||
61 | </table> | ||
62 | </div> | ||
63 | |||
64 | {% endblock %} | ||