diff --git a/corepos/db/model.py b/corepos/db/model.py index 7bde147249ec6440bd9f5bb0d268255945c6f806..dee6ad6565f662f810a8b7e4875fce1c195387bc 100644 --- a/corepos/db/model.py +++ b/corepos/db/model.py @@ -327,28 +327,28 @@ class Employee(Base): """ __tablename__ = 'employees' - emp_no = sa.Column(sa.SmallInteger(), primary_key=True, autoincrement=False, nullable=False) + number = sa.Column('emp_no', sa.SmallInteger(), primary_key=True, autoincrement=False, nullable=False) - CashierPassword = sa.Column(sa.String(length=50), nullable=True) + cashier_password = sa.Column('CashierPassword', sa.String(length=50), nullable=True) - AdminPassword = sa.Column(sa.String(length=50), nullable=True) + admin_password = sa.Column('AdminPassword', sa.String(length=50), nullable=True) - FirstName = sa.Column(sa.String(length=255), nullable=True) + first_name = sa.Column('FirstName', sa.String(length=255), nullable=True) - LastName = sa.Column(sa.String(length=255), nullable=True) + last_name = sa.Column('LastName', sa.String(length=255), nullable=True) - JobTitle = sa.Column(sa.String(length=255), nullable=True) + job_title = sa.Column('JobTitle', sa.String(length=255), nullable=True) - EmpActive = sa.Column(sa.Boolean(), nullable=True) + active = sa.Column('EmpActive', sa.Boolean(), nullable=True) - frontendsecurity = sa.Column(sa.SmallInteger(), nullable=True) + frontend_security = sa.Column('frontendsecurity', sa.SmallInteger(), nullable=True) - backendsecurity = sa.Column(sa.SmallInteger(), nullable=True) + backend_security = sa.Column('backendsecurity', sa.SmallInteger(), nullable=True) - birthdate = sa.Column(sa.DateTime(), nullable=True) + birth_date = sa.Column('birthdate', sa.DateTime(), nullable=True) def __str__(self): - return ' '.join([self.FirstName or '', self.LastName or '']).strip() + return ' '.join([self.first_name or '', self.last_name or '']).strip() @six.python_2_unicode_compatible