forked from crunk/distribusi-verse
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
501 B
17 lines
501 B
3 years ago
|
from app import db
|
||
|
from flask_login import UserMixin
|
||
|
|
||
|
|
||
|
class User(UserMixin, db.Model):
|
||
|
"""User model class for a user in distribusi-verse"""
|
||
|
|
||
|
__tablename__ = "users"
|
||
|
|
||
|
id = db.Column(db.Integer, primary_key=True)
|
||
|
distribusiname = db.Column(db.String(100), unique=True, nullable=True)
|
||
|
email = db.Column(db.String(150), unique=True, nullable=False)
|
||
|
pwd = db.Column(db.String(300), nullable=False, unique=False)
|
||
|
|
||
|
def __repr__(self):
|
||
|
return "<User %r>" % self.username
|