更新 app.py
parent
97a56e0e2f
commit
4c8d30da70
|
|
@ -44,6 +44,9 @@ def valid_login(username, password):
|
||||||
# 假设用户名是admin且密码是secret
|
# 假设用户名是admin且密码是secret
|
||||||
return username == 'admin' and password == '1'
|
return username == 'admin' and password == '1'
|
||||||
|
|
||||||
|
@app.route('/forget', methods=['GET', 'POST'])
|
||||||
|
def forget_page():
|
||||||
|
return render_template('forget.html')
|
||||||
@app.route('/home')
|
@app.route('/home')
|
||||||
def home():
|
def home():
|
||||||
if 'username' in session:
|
if 'username' in session:
|
||||||
|
|
|
||||||
Reference in New Issue