diff --git a/fec/legal/templates/layouts/legal-doc-search-results.jinja b/fec/legal/templates/layouts/legal-doc-search-results.jinja index 1e8c59dda8..83d0c37b98 100644 --- a/fec/legal/templates/layouts/legal-doc-search-results.jinja +++ b/fec/legal/templates/layouts/legal-doc-search-results.jinja @@ -30,11 +30,9 @@
-
- - {% block filters %} - {% endblock %} -
+ + {% block filters %} + {% endblock %}
diff --git a/fec/legal/templates/legal-search-results-adrs.jinja b/fec/legal/templates/legal-search-results-adrs.jinja index 5c3a858a3c..6babc204f0 100644 --- a/fec/legal/templates/legal-search-results-adrs.jinja +++ b/fec/legal/templates/legal-search-results-adrs.jinja @@ -9,17 +9,19 @@ {% endblock %} {% block filters %} - {{ legal.keyword_search(result_type, query) }} -
- - -
-
- - -
-
- +
+ {{ legal.keyword_search(result_type, query) }} +
+ + +
+
+ + +
+
+ +
{% endblock %} diff --git a/fec/legal/templates/legal-search-results-afs.jinja b/fec/legal/templates/legal-search-results-afs.jinja index 2043c9097d..0148b63764 100644 --- a/fec/legal/templates/legal-search-results-afs.jinja +++ b/fec/legal/templates/legal-search-results-afs.jinja @@ -9,6 +9,7 @@ {% endblock %} {% block filters %} +
{{ legal.keyword_search(result_type, query) }}
@@ -21,6 +22,7 @@
+
{% endblock %} {% block message %} diff --git a/fec/legal/templates/legal-search-results-murs.jinja b/fec/legal/templates/legal-search-results-murs.jinja index eab9d3f902..ed4b2ab700 100644 --- a/fec/legal/templates/legal-search-results-murs.jinja +++ b/fec/legal/templates/legal-search-results-murs.jinja @@ -9,17 +9,47 @@ {% endblock %} {% block filters %} - {{ legal.keyword_search(result_type, query) }} -
- - -
-
- - -
-
- +
+ {{ legal.keyword_search(result_type, query) }} +
+ + +
+
+ + +
+
+ Case open date range +
+
+ + +
+
-
+
+ + +
+
+
+
+ Case close date range +
+
+ + +
+
-
+
+ + +
+
+
+
+ +
{% endblock %} diff --git a/fec/legal/templates/partials/legal-pagination.jinja b/fec/legal/templates/partials/legal-pagination.jinja index 6edcbbd258..98ceefed22 100644 --- a/fec/legal/templates/partials/legal-pagination.jinja +++ b/fec/legal/templates/partials/legal-pagination.jinja @@ -2,12 +2,12 @@
{{ results.offset | int + 1 }}–{{ results.offset | int + results[result_type + '_returned'] | int }} of about {{ results.total_all }}
{% if results.offset | int > 0 %} - + {% else %} Previous {% endif %} {% if results.offset | int + results.limit | int < results.total_all | int %} - + {% else %} Next {% endif %} diff --git a/fec/legal/templates/partials/legal-search-results-mur.jinja b/fec/legal/templates/partials/legal-search-results-mur.jinja index ac07a9e2cf..3769b0d6aa 100644 --- a/fec/legal/templates/partials/legal-search-results-mur.jinja +++ b/fec/legal/templates/partials/legal-search-results-mur.jinja @@ -24,7 +24,8 @@ {{ highlight|safe }} … {% endfor %}
-
Date closed: {{ mur.close_date | date('%Y') | default('Unknown', True) }}
+
Date opened: {{ mur.open_date | date('%m/%d/%Y') | default('Unknown', True) }}
+
Date closed: {{ mur.close_date | date('%m/%d/%Y') | default('Unknown', True) }}
{% if mur.mur_type == 'current' %} {# Archived MUR subjects are a tree-structure so we don't render them inline #}
diff --git a/fec/legal/views.py b/fec/legal/views.py index c734b77647..2bc00baa9f 100644 --- a/fec/legal/views.py +++ b/fec/legal/views.py @@ -128,8 +128,21 @@ def legal_doc_search_mur(request): offset = request.GET.get('offset', 0) case_no = request.GET.get('case_no', '') case_respondents = request.GET.get('case_respondents', '') - - results = api_caller.load_legal_search_results(query, 'murs', offset=offset, case_no=case_no, case_respondents=case_respondents) + case_min_open_date = request.GET.get('case_min_open_date', '') + case_max_open_date = request.GET.get('case_max_open_date', '') + case_min_close_date = request.GET.get('case_min_close_date', '') + case_max_close_date = request.GET.get('case_max_close_date', '') + + results = api_caller.load_legal_search_results( + query, 'murs', + offset=offset, + case_no=case_no, + case_respondents=case_respondents, + case_min_open_date=case_min_open_date, + case_max_open_date=case_max_open_date, + case_min_close_date=case_min_close_date, + case_max_close_date=case_max_close_date + ) return render(request, 'legal-search-results-murs.jinja', { 'parent': 'legal', @@ -137,6 +150,10 @@ def legal_doc_search_mur(request): 'result_type': 'murs', 'case_no': case_no, 'case_respondents': case_respondents, + 'case_min_open_date': case_min_open_date, + 'case_max_open_date': case_max_open_date, + 'case_min_close_date': case_min_close_date, + 'case_max_close_date': case_max_close_date, 'query': query })