MobileBlur

stories.py at [8df0d5f377]
Login

stories.py at [8df0d5f377]

File applications/mobileblur/controllers/stories.py artifact fbf9de8ba7 part of check-in 8df0d5f377


# -*- coding: utf-8 -*-

from pprint import pprint

def view():
    stories = newsblur.feed(request.vars["feed_id"])["stories"]
    story = [story for story in stories if story["id"]==request.vars["story"]][0]
    return dict(story=story, feed_id=request.vars["feed_id"])

def mark_read():
    results = newsblur.mark_story_as_read(request.vars["story_id"], request.vars["feed_id"])
    redirect(URL("default", "index"))