Merge branch 'QA' into bug/issue2
This commit is contained in:
11
server.py
11
server.py
@@ -26,11 +26,12 @@ def index():
|
||||
|
||||
@app.route('/showSummary',methods=['POST'])
|
||||
def showSummary():
|
||||
club = [club for club in clubs if club['email'] == request.form['email']]
|
||||
if club:
|
||||
return render_template('welcome.html', club=club[0], competitions=competitions)
|
||||
flash("Sorry, that email wasn't found")
|
||||
return redirect(url_for('index'))
|
||||
try:
|
||||
club = [club for club in clubs if club['email'] == request.form['email']][0]
|
||||
return render_template('welcome.html', club=club, competitions=competitions)
|
||||
except IndexError:
|
||||
flash("Sorry, that email wasn't found")
|
||||
return redirect(url_for('index'))
|
||||
|
||||
@app.route('/book/<competition>/<club>')
|
||||
def book(competition,club):
|
||||
|
||||
Reference in New Issue
Block a user