diff --git a/templates/rangefilter/date_filter.html b/templates/rangefilter/date_filter.html new file mode 100644 index 0000000..1666b37 --- /dev/null +++ b/templates/rangefilter/date_filter.html @@ -0,0 +1,138 @@ +{% load i18n rangefilter_compat %} +

{{ title }}

+ + +{% comment %} +Force load jsi18n, issues #5 +https://github.com/django/django/blob/stable/1.10.x/django/contrib/admin/templates/admin/change_list.html#L7 +{% endcomment %} + + + +{% block quick-select-choices %}{% endblock %} +
+ + {{ spec.form.as_p }} + {% for choice in choices %} + + {% endfor %} +
diff --git a/templates/rangefilter/date_filter_1_8.html b/templates/rangefilter/date_filter_1_8.html new file mode 100644 index 0000000..09093d3 --- /dev/null +++ b/templates/rangefilter/date_filter_1_8.html @@ -0,0 +1,94 @@ +{% load i18n rangefilter_compat %} +

{{ title }}

+ + +{% comment %} +Force load jsi18n, issues #5 +https://github.com/django/django/blob/stable/1.8.x/django/contrib/admin/templates/admin/change_list.html#L7 +{% endcomment %} + + + +
+
+ {{ spec.form }} + {% for choice in choices %} + + {% endfor %} +
+ + +
+
+
diff --git a/templates/rangefilter/date_filter_csp.html b/templates/rangefilter/date_filter_csp.html new file mode 100644 index 0000000..98b493c --- /dev/null +++ b/templates/rangefilter/date_filter_csp.html @@ -0,0 +1,145 @@ +{% load i18n rangefilter_compat %} +

{{ title }}

+ + + +{% comment %} +Force load jsi18n, issues #5 +https://github.com/django/django/blob/stable/1.10.x/django/contrib/admin/templates/admin/change_list.html#L7 +{% endcomment %} + + + + +
+
+ {{ spec.form.as_p }} + {% for choice in choices %} + + {% endfor %} +
+ + +
+
+
+ +{% comment %} JS not requiring template variables refactored as an iife {% endcomment %} + diff --git a/templates/rangefilter/date_range_quick_select_list_filter.html b/templates/rangefilter/date_range_quick_select_list_filter.html new file mode 100644 index 0000000..ec34a05 --- /dev/null +++ b/templates/rangefilter/date_range_quick_select_list_filter.html @@ -0,0 +1,16 @@ +{% extends 'rangefilter/date_filter.html' %} + +{% block quick-select-choices %} + {% comment %} + The following code under the