isPermaLink in feeds.py (RSS only)

master
pictuga 2013-11-16 19:07:25 +01:00
parent 68768dd6e4
commit 91251ec306
1 changed files with 18 additions and 0 deletions

View File

@ -407,6 +407,13 @@ class FeedItem(FeedBase):
pass
def getIsPermaLink(self):
return ""
def setIsPermaLink(self, value):
pass
def getDesc(self):
return ""
@ -461,6 +468,7 @@ class FeedItem(FeedBase):
description = desc = FeedDescriptor('desc')
content = FeedDescriptor('content')
id = FeedDescriptor('id')
isPermaLink = FeedBool('isPermaLink')
time = FeedTime('time')
updated = FeedTime('updated')
@ -540,6 +548,16 @@ class FeedItemRSS(FeedItem):
element.text = value
def getIsPermaLink(self):
return self.xget('rssfake:guid/@isPermaLink|guid/@isPermaLink')
def setIsPermaLink(self, value):
table = { 'rdf:rdf': 'rssfake:guid',
'channel': 'guid'}
element = self.xgetCreate(table)
element.attrib['isPermaLink'] = value
def getTime(self):
return self.xval('rssfake:pubDate|pubDate')