Modify landing page can personnalize the server name and make a little description
This commit is contained in:
@@ -25,6 +25,8 @@ SETUID = app.config['SETUID']
|
||||
MAIL_SERVER = app.config['MAIL_SERVER']
|
||||
XMPP_SERVER = app.config['XMPP_SERVER']
|
||||
BACKUP_TIME = app.config['BACKUP_TIME']
|
||||
SERVER_TITLE = app.config['TITLE_SERVER']
|
||||
SERVER_DESC = app.config['DESC_SERVER']
|
||||
##################################################################################################
|
||||
|
||||
|
||||
@@ -52,7 +54,8 @@ def index():
|
||||
return render_template('inscription.html', signin_enable=app.config['SIGNIN_ENABLE'],
|
||||
token=token, hostname=hostname,
|
||||
url_inscription=url_inscription,
|
||||
MAIL_SERVER=MAIL_SERVER)
|
||||
server_title=SERVER_TITLE,
|
||||
mail_server=MAIL_SERVER)
|
||||
else:
|
||||
return redirect(url_for('loginlogout.login', _external=True))
|
||||
|
||||
@@ -63,9 +66,9 @@ def login():
|
||||
else :
|
||||
resp = redirect(url_for('loginlogout.login', _external=True))
|
||||
if request.method == 'POST' :
|
||||
user = request.form['user']
|
||||
password = request.form['passwd']
|
||||
totp = request.form['code_totp']
|
||||
user = str(request.form['user'])
|
||||
password = str(request.form['passwd'])
|
||||
totp = str(request.form['code_totp'])
|
||||
|
||||
conn = sqlite3.connect(DATABASE) # Connexion à la base de donnée
|
||||
cursor = conn.cursor() # Création de l'objet "curseur"
|
||||
@@ -85,7 +88,11 @@ def login():
|
||||
else:
|
||||
flash(u"L'utilisateur n'existe pas", 'error')
|
||||
else:
|
||||
resp = render_template('accueil.html', signin_enable=app.config['SIGNIN_ENABLE'])
|
||||
resp = render_template('accueil.html',
|
||||
server_title=SERVER_TITLE,
|
||||
server_desc=SERVER_DESC,
|
||||
mail_server=MAIL_SERVER,
|
||||
signin_enable=app.config['SIGNIN_ENABLE'])
|
||||
return resp
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user