summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorluxagraf <sng@luxagraf.net>2017-10-20 12:57:55 -0700
committerluxagraf <sng@luxagraf.net>2017-10-20 12:57:55 -0700
commite392dc34c836dc529a72b603c5ee5c9b917c2f37 (patch)
treeb0e400fac3b415bebc0a6c46d9f38ee04edaf818 /app
parentbd1adb4927695ed0ce3ac94d90c68bd61e440275 (diff)
added dates to RSS
Diffstat (limited to 'app')
-rw-r--r--app/jrnl/views.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/app/jrnl/views.py b/app/jrnl/views.py
index bbeccca..f69fd8d 100644
--- a/app/jrnl/views.py
+++ b/app/jrnl/views.py
@@ -114,3 +114,10 @@ class JrnlRSSFeedView(Feed):
def items(self):
return Entry.objects.filter(status__exact=1).order_by('-pub_date')[:10]
+
+ def item_pubdate(self, item):
+ """
+ Takes an item, as returned by items(), and returns the item's
+ pubdate.
+ """
+ return item.pub_date