summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/toaster/toastergui/templates/filtersnippet.html
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/toaster/toastergui/templates/filtersnippet.html')
-rw-r--r--bitbake/lib/toaster/toastergui/templates/filtersnippet.html39
1 files changed, 39 insertions, 0 deletions
diff --git a/bitbake/lib/toaster/toastergui/templates/filtersnippet.html b/bitbake/lib/toaster/toastergui/templates/filtersnippet.html
new file mode 100644
index 0000000..90ffd3d
--- /dev/null
+++ b/bitbake/lib/toaster/toastergui/templates/filtersnippet.html
@@ -0,0 +1,39 @@
1{% load projecttags %}
2<!-- '{{f.class}}' filter -->
3<form id="filter_{{f.class}}" class="modal hide fade" tabindex="-1" role="dialog" aria-hidden="true">
4 <input type="hidden" name="search" value="{{request.GET.search}}"/>
5 <div class="modal-header">
6 <button type="button" class="close" data-dismiss="modal" aria-hidden="true">x</button>
7 {% if search_term %}
8 <h3>Filter {{total_count}} {%if filter_search_display%}{{filter_search_display|title}}{%else%}{{objectname|title}}{%endif%} matching '{{search_term}}' by '{{tc.name}}'</h3>
9 {% else %}
10 <h3>Filter {%if filter_search_display%}{{filter_search_display|title}}{%else%}{{objectname|title}}{%endif%} by '{{tc.name}}'</h3>
11 {% endif %}
12 </div>
13 <div class="modal-body">
14 <p>{{f.label}}</p>
15 <label class="radio">
16 <input type="radio" name="filter" {%if request.GET.filter%}{{f.options|check_filter_status:request.GET.filter}} {%else%} checked {%endif%} value=""> All {%if filter_search_display%}{{filter_search_display|title}}{%else%}{{objectname|title}}{%endif%} ({{total_count}})
17 </label>
18 {% for option in f.options %}
19 {% if option.2 %}
20 <label class="radio">
21 <input type="radio" name="filter" {%if request.GET.filter == option.1 %}checked{%endif%} value="{{option.1}}"> {{option.0}} ({{option.2}})
22 {% else %}
23 <label class="radio muted">
24 <input type="radio" name="filter" disabled {%if request.GET.filter == option.1 %}checked{%endif%} value="{{option.1}}"> {{option.0}} ({{option.2}})
25 {% endif %}
26 {% if option.3 %}<i class="icon-question-sign get-help" data-placement="right" title="{{option.3}}"></i>{% endif %}
27 </label>
28 {% endfor %}
29 </div>
30 <div class="modal-footer">
31 <button type="submit" class="btn btn-primary">Apply</button>
32 {% if request.GET.filter %}
33 {% if request.GET.filter|string_remove_regex:':.*' != f.options.0.1|string_remove_regex:':.*' %}
34 <span class="help-inline pull-left">You can only apply one filter to the table. This filter will override the current filter.</span>
35 {% endif %}
36 {% endif %}
37 </div>
38</form>
39