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.html114
1 files changed, 61 insertions, 53 deletions
diff --git a/bitbake/lib/toaster/toastergui/templates/filtersnippet.html b/bitbake/lib/toaster/toastergui/templates/filtersnippet.html
index 4c2c53e586..1286ca315f 100644
--- a/bitbake/lib/toaster/toastergui/templates/filtersnippet.html
+++ b/bitbake/lib/toaster/toastergui/templates/filtersnippet.html
@@ -6,59 +6,67 @@
6 <div class="modal-dialog"> 6 <div class="modal-dialog">
7 <div class="modal-content"> 7 <div class="modal-content">
8 <form> 8 <form>
9 <input type="hidden" name="search" value="{%if request.GET.search %}{{request.GET.search}}{%endif%}"/> 9 <input type="hidden" name="search" value="{%if request.GET.search %}{{request.GET.search}}{%endif%}"/>
10 <div class="modal-header"> 10 <div class="modal-header">
11 <button type="button" class="close" data-dismiss="modal" aria-hidden="true">x</button> 11 <button type="button" class="close" data-dismiss="modal" aria-hidden="true">x</button>
12 {% if search_term %} 12 {% if search_term %}
13 <h3>Filter {{total_count}} {%if filter_search_display%}{{filter_search_display|title}}{%else%}{{objectname|title}}{%endif%} matching '{{search_term}}' by '{{tc.name}}'</h3> 13 <h3>Filter {{total_count}} {%if filter_search_display%}{{filter_search_display|title}}{%else%}{{objectname|title}}{%endif%} matching '{{search_term}}' by '{{tc.name}}'</h3>
14 {% else %} 14 {% else %}
15 <h3>Filter {%if filter_search_display%}{{filter_search_display|title}}{%else%}{{objectname|title}}{%endif%} by '{{tc.name}}'</h3> 15 <h3>Filter {%if filter_search_display%}{{filter_search_display|title}}{%else%}{{objectname|title}}{%endif%} by '{{tc.name}}'</h3>
16 {% endif %} 16 {% endif %}
17 </div> 17 </div>
18 <div class="modal-body"> 18 <div class="modal-body">
19 <p>{{f.label}}</p> 19 <p>{{f.label}}</p>
20 <label class="radio"> 20 <div class="radio">
21 <input type="radio" name="filter" {%if request.GET.filter%}{{f.options|check_filter_status:request.GET.filter}} {%else%} checked {%endif%} value="" data-key="{{key}}"> All {%if filter_search_display%}{{filter_search_display|title}}{%else%}{{objectname|title}}{%endif%} 21 <label>
22 </label> 22 <input type="radio" name="filter" {%if request.GET.filter%}{{f.options|check_filter_status:request.GET.filter}} {%else%} checked {%endif%} value="" data-key="{{key}}"> All {%if filter_search_display%}{{filter_search_display|title}}{%else%}{{objectname|title}}{%endif%}
23 {% for option in f.options %} 23 </label>
24 {% if option.1 == 'daterange' %} 24 </div>
25 <div class="form-inline"> 25 {% for option in f.options %}
26 <label class="radio"> 26 <div class="radio">
27 <input type="radio" name="filter" id="filter_value_{{key}}" {%if key == daterange_selected %}checked{%endif%} value="{{option.1}}" data-key="{{key}}"> {{option.0}} 27 {% if option.1 == 'daterange' %}
28 {% else %} 28 <label>
29 {% if 1 %} 29 <input type="radio" name="filter" id="filter_value_{{key}}" {%if key == daterange_selected %}checked{%endif%} value="{{option.1}}" data-key="{{key}}"> {{option.0}}
30 <label class="radio"> 30 {% else %}
31 <input type="radio" name="filter" {%if request.GET.filter == option.1 %}checked{%endif%} value="{{option.1}}" data-key="{{key}}"> {{option.0}} 31 {% if 1 %}
32 {% comment "do not disable radio selections by count for now" %}{% else %} 32 <label>
33 <label class="radio muted"> 33 <input type="radio" name="filter" {%if request.GET.filter == option.1 %}checked{%endif%} value="{{option.1}}" data-key="{{key}}"> {{option.0}}
34 <input type="radio" name="filter" disabled {%if request.GET.filter == option.1 %}checked{%endif%} value="{{option.1}}" data-key="{{key}}"> {{option.0}} 34 {% comment "do not disable radio selections by count for now" %}{% else %}
35 {% endcomment %}{% endif %} 35 <label class="text-muted">
36 {% endif %} 36 <input type="radio" name="filter" disabled {%if request.GET.filter == option.1 %}checked{%endif%} value="{{option.1}}" data-key="{{key}}"> {{option.0}}
37 {% if option.3 %}<i class="icon-question-sign get-help" data-placement="right" title="{{option.3}}"></i>{% endif %} 37 {% endcomment %}{% endif %}
38 </label> 38 {% endif %}
39 {% if option.1 == 'daterange' %} 39 {% if option.3 %}<i class="icon-question-sign get-help" data-placement="right" title="{{option.3}}"></i>{% endif %}
40 <input type="text" id="date_from_{{key}}" name="date_from_{{key}}" disabled class="input-sm" /><label class="help-inline">to</label> 40 </label></div>
41 <input type="text" id="date_to_{{key}}" name="date_to_{{key}}" disabled class="input-sm" /> 41 {% if option.1 == 'daterange' %}
42 <label class="help-inline get-help" >(dd/mm/yyyy)</label> 42 <input type="text" id="date_from_{{key}}" name="date_from_{{key}}" disabled class="input-sm" /><label class="help-inline">to</label>
43 </div> 43 <input type="text" id="date_to_{{key}}" name="date_to_{{key}}" disabled class="input-sm" />
44 {% endif %} 44 <label class="help-inline get-help" >(dd/mm/yyyy)</label>
45 {% endfor %} 45 </div>
46 <!-- daterange persistence --> 46 {% endif %}
47 {% if last_date_from and last_date_to %} 47 {% endfor %}
48 <input type="hidden" id="last_date_from_{{key}}" name="last_date_from" value="{{last_date_from}}"/> 48 <!-- daterange persistence -->
49 <input type="hidden" id="last_date_to_{{key}}" name="last_date_to" value="{{last_date_to}}"/> 49 {% if last_date_from and last_date_to %}
50 {% endif %} 50 <input type="hidden" id="last_date_from_{{key}}" name="last_date_from" value="{{last_date_from}}"/>
51 </div> 51 <input type="hidden" id="last_date_to_{{key}}" name="last_date_to" value="{{last_date_to}}"/>
52 <div class="modal-footer"> 52 {% endif %}
53 <button type="submit" class="btn btn-primary" data-key="{{key}}">Apply</button> 53 </div>
54 {% if request.GET.filter %} 54 <div class="modal-footer">
55 {% if request.GET.filter|string_remove_regex:':.*' != f.options.0.1|string_remove_regex:':.*' %} 55 <div class="row">
56 <span class="help-inline pull-left">You can only apply one filter to the table. This filter will override the current filter.</span> 56 <div class="col-md-6">
57 {% endif %} 57 <button type="submit" class="btn btn-primary" data-key="{{key}}">Apply</button>
58 {% endif %} 58 </div>
59 </div> 59 <div class="col-md-6">
60 {% if request.GET.filter %}
61 {% if request.GET.filter|string_remove_regex:':.*' != f.options.0.1|string_remove_regex:':.*' %}
62 <p class="text-right text-muted">You can only apply one filter to the table. This filter will override the current filter.</p>
63 {% endif %}
64 {% endif %}
65 </div>
66 </div>
67 </div>
60 </form> 68 </form>
61 </div><!-- /.modal-content --> 69 </div><!-- /.modal-content -->
62 </div><!-- /.modal-dialog --> 70</div><!-- /.modal-dialog -->
63</div> <!--/.modal --> 71</div> <!--/.modal -->
64{% endwith %} 72{% endwith %}