Update settings page.

This commit is contained in:
Patrick Jentsch
2019-07-09 16:18:21 +02:00
parent 8458271a5c
commit 678ac670ea
3 changed files with 16 additions and 12 deletions

View File

@@ -125,9 +125,9 @@ def password_reset(token):
title='Password Reset')
@auth.route('/account', methods=['GET', 'POST'])
@auth.route('/settings', methods=['GET', 'POST'])
@login_required
def account():
def settings():
form = ChangeAccountForm()
if form.validate_on_submit():
flash('It is just a test, nothing changed.')
@@ -142,6 +142,6 @@ def account():
if form.password.data:
current_user.password = form.password.data
db.session.commit()
return redirect(url_for('auth.account'))
return render_template('auth/account.html.j2', form=form,
title='Account')
return redirect(url_for('auth.settings'))
return render_template('auth/settings.html.j2', form=form,
title='Settings')