Index: filters/humanize_dates.py |
diff --git a/filters/humanize_dates.py b/filters/humanize_dates.py |
new file mode 100644 |
index 0000000000000000000000000000000000000000..a85cad30c5133391cbbf042cc0f64bf76bef5c9f |
--- /dev/null |
+++ b/filters/humanize_dates.py |
@@ -0,0 +1,9 @@ |
+import datetime, copy |
+ |
+def humanize_dates (unformatted_list): |
Sebastian Noack
2016/02/02 16:50:21
Nit: No space before arguments list.
juliandoucette
2016/02/04 10:04:22
Done.
|
+ formatted_list = copy.deepcopy(unformatted_list); |
+ for item in formatted_list: |
Sebastian Noack
2016/02/02 16:50:21
While looking at the template, is there actually a
juliandoucette
2016/02/04 10:04:22
Done.
|
+ item[0] = datetime.datetime.strftime( |
+ datetime.datetime.strptime(item[0], "%Y-%m-%d"), |
+ "%B %d, %Y") |
+ return formatted_list |