diff --git a/corepos/db/office_op/model.py b/corepos/db/office_op/model.py index 182f3fe..1cb0bd9 100644 --- a/corepos/db/office_op/model.py +++ b/corepos/db/office_op/model.py @@ -108,6 +108,32 @@ class TableSyncRule(Base): return "{}: {}".format(self.table_name, self.rule) +class User(Base): + """ + Represents a user within CORE Office. + """ + __tablename__ = 'Users' + + name = sa.Column(sa.String(length=50), nullable=False, primary_key=True) + + password = sa.Column(sa.String(length=255), nullable=True) + + salt = sa.Column(sa.String(length=10), nullable=True) + + uid = sa.Column(sa.String(length=4), nullable=True) + + session_id = sa.Column(sa.String(length=50), nullable=True) + + real_name = sa.Column(sa.String(length=75), nullable=True) + + email = sa.Column(sa.String(length=75), nullable=True) + + totp_url = sa.Column('totpURL', sa.String(length=255), nullable=True) + + def __str__(self): + return self.name or "" + + class Store(Base): """ Represents a known store.