Forgot to set default for the GET view
This commit is contained in:
+4
-2
@@ -7,8 +7,10 @@ from app import app, db
|
|||||||
@app.route('/', methods=['GET'])
|
@app.route('/', methods=['GET'])
|
||||||
def get_home():
|
def get_home():
|
||||||
"""Render website's home page."""
|
"""Render website's home page."""
|
||||||
targets = db.session.query(target).all()
|
clientId = "default"
|
||||||
return render_template('home.html', targets=targets)
|
targets = db.session.query(target)
|
||||||
|
targets = targets.where(target.clientId == clientId)
|
||||||
|
return render_template('home.html', targets=targets.all(), clientId=clientId)
|
||||||
|
|
||||||
@app.route('/', methods=['POST'])
|
@app.route('/', methods=['POST'])
|
||||||
def post_home():
|
def post_home():
|
||||||
|
|||||||
Reference in New Issue
Block a user