Exemplo n.º 1
0
def au_article_get_by_id(id):
    article = Article()
    a = article.get_article_by_id(id)
    if a is None:
        abort(404)
    else:
        return a.content
Exemplo n.º 2
0
def au_artile_create():
    title = request.form["title"]
    alias = request.form["alias"]
    content = request.form["content"]
    article = Article()
    a = article.create(title, alias, content)
    return redirect(url_for("au_article_get_by_id", id=a.get_id()))
Exemplo n.º 3
0
def au_entry():
    a = Article()
    articles = a.get_articles()
    return render_template(au_temp + "/article/index.html", articles=articles)