From c8e7be766d00c38c7d62f8519eee0df2f0565e5d Mon Sep 17 00:00:00 2001 From: DewGew Date: Thu, 2 Nov 2023 15:51:20 +0100 Subject: [PATCH] Add change armlevel names in settingspage --- modules/routes.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/modules/routes.py b/modules/routes.py index c24e0b8..4755ed8 100644 --- a/modules/routes.py +++ b/modules/routes.py @@ -66,7 +66,7 @@ def settings(): dbuser.domopass = request.form.get('domopass') dbuser.roomplan = request.form.get('roomplan') dbuser.password = request.form.get('uipassword') # Remove ? - dbuser.googleassistant = (request.form.get('googleassistant') == 'true') # Remove ? + dbuser.googleassistant = (request.form.get('googleassist') == 'true') # Remove ? db.session.add(dbuser) db.session.commit() @@ -81,8 +81,10 @@ def settings(): dbsettings.use_ssl = (request.form.get('ssl') == 'true') dbsettings.ssl_cert = request.form.get('sslcert') dbsettings.ssl_key = request.form.get('sslkey') - # dbsettings.armhome = request.form.get('armhome') - # dbsettings.armaway = request.form.get('armaway') + armhome = request.form.get('armhome') + armaway = request.form.get('armaway') + + dbsettings.armlevels.update({'armhome': armhome, 'armaway': armaway}) db.session.add(dbsettings) db.session.commit()