예제 #1
0
 def post(self):
     rssUrl = self.request.get("rssUrl").strip()
     if RSS.all().filter("rssUrl =", rssUrl).count() == 0 and rssUrl:
         rss = RSS()
         rss.rssUrl = rssUrl
         rss.put()
     self.render("templates/index.html", {"RSSs": RSS.all()})
예제 #2
0
파일: main.py 프로젝트: nickyfoto/reader
 def addItem(self, c, item_key):
     item = RSS(title = c.title,
                    description = c.description,
                    published = c.published,
                    published_parsed = mktime(c.published_parsed),
                    link = c.link,
                    content = c.content[0]['value'],
                    parent = item_key)
     item.put()