Fixed up database modules in webapp

This commit is contained in:
Jeremy Zhang
2017-06-04 05:05:55 +00:00
parent 91384cd166
commit c76e0a4993
9 changed files with 64 additions and 64 deletions

View File

@ -4,10 +4,10 @@ import time
class AuthenticatedUsers(db.Model):
__tablename__ = "authenticated_users"
id = db.Column(db.Integer, primary_key=True) # Auto increment id
guild_id = db.Column(db.String(255)) # Guild pretaining to the authenticated user
client_id = db.Column(db.String(255)) # Client ID of the authenticated user
last_timestamp = db.Column(db.TIMESTAMP) # The timestamp of when the user has last sent the heartbeat
id = db.Column(db.Integer, primary_key=True) # Auto increment id
guild_id = db.Column(db.String(255), nullable=False) # Guild pretaining to the authenticated user
client_id = db.Column(db.String(255), nullable=False) # Client ID of the authenticated user
last_timestamp = db.Column(db.TIMESTAMP, nullable=False) # The timestamp of when the user has last sent the heartbeat
def __init__(self, guild_id, client_id):
self.guild_id = guild_id