def reaction(_id): context = {} context["reaction"] = reactions.lookup(_id=_id) context["article"] = articles.lookup(_id=context["reaction"]['article_id']) context["disqus"] = disqus.get(current_user, context["article"], reaction=context["reaction"]) return render_template('reaction.html', **context)
def view(_id): context = {} a = articles.lookup(_id=_id) if not a: return render_template('404.html') if "abstract" not in a and "uuid" in a: a = articles.get_details(a) context["article"] = a context["reactions"] = reactions.lookup(article_id=_id, mult=True) context["disqus"] = disqus.get(current_user, context["article"]) return render_template('article.html', **context)