python学习

This commit is contained in:
2019-07-29 15:28:02 +08:00
parent 5ee5b5035c
commit 04327fbd47
18 changed files with 709 additions and 274 deletions

View File

@@ -36,9 +36,15 @@ def login():
return jsonify(resp)
if user_info.login_pwd != UserService.genePwd(login_pwd, user_info.login_salt):
resp['code'] = -1
resp['msg'] = "请输入正确的登录用户名和密码-2~~"
return jsonify(resp)
resp['code'] = -1
resp['msg'] = "请输入正确的登录用户名和密码-2~~"
return jsonify(resp)
if user_info.status !=1:
resp['code'] = -1
resp['msg'] = "帐号已被禁用,请联系管理员处理~~"
return jsonify(resp)
response = make_response(json.dumps(resp))
response.set_cookie(app.config['AUTH_COOKIE_NAME'], '%s#%s' % (