diff mbox series

[v2,4/4] templates: Don't show forced filters

Message ID 20180929212610.29905-4-stephen@that.guru
State Accepted
Headers show
Series [v2,1/4] filters: Return dictionaries | expand

Commit Message

Stephen Finucane Sept. 29, 2018, 9:26 p.m. UTC
No point in showing a filter that you can't change.

Signed-off-by: Stephen Finucane <stephen@that.guru>
---
 patchwork/templates/patchwork/filters.html | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/patchwork/templates/patchwork/filters.html b/patchwork/templates/patchwork/filters.html
index 9b0c4cb2..41ed2c26 100644
--- a/patchwork/templates/patchwork/filters.html
+++ b/patchwork/templates/patchwork/filters.html
@@ -143,12 +143,14 @@  $(document).ready(function() {
  <div id="filterform" style="padding-top: 1em; display: none">
   <form class="form-horizontal" method="get">
    {% for filter in filters.available_filters %}
+   {% if not filter.forced %}
    <div class="form-group">
     <label class="col-sm-2 control-label">{{ filter.name }}</label>
     <div class="col-sm-5">
       {{ filter.form }}
     </div>
    </div>
+   {% endif %}
    {% endfor %}
    <div class="form-group">
     <div class="col-sm-offset-2 col-sm-5">