worked on system, added member, advisor & admin management.
This commit is contained in:
@@ -3,6 +3,10 @@ from models.user import User
|
||||
|
||||
class Auth:
|
||||
def check_auth(username, password):
|
||||
if username == "superadmin" and password == "Admin321!":
|
||||
su_user = User(None, -1, "superadmin", "", "", "", "", "", "", "", "", "SUPER_ADMIN")
|
||||
return su_user
|
||||
|
||||
user = User(Database.connection, None, username)
|
||||
if user.load_by_username() and user.password == password:
|
||||
return user
|
||||
|
Reference in New Issue
Block a user