Add lane_op model for Department
This commit is contained in:
parent
07e3c62b6c
commit
092884eab3
|
@ -32,6 +32,47 @@ from sqlalchemy.ext.declarative import declarative_base
|
||||||
Base = declarative_base()
|
Base = declarative_base()
|
||||||
|
|
||||||
|
|
||||||
|
class Department(Base):
|
||||||
|
"""
|
||||||
|
Represents a department within the organization.
|
||||||
|
"""
|
||||||
|
__tablename__ = 'departments'
|
||||||
|
|
||||||
|
number = sa.Column('dept_no', sa.SmallInteger(), nullable=False,
|
||||||
|
primary_key=True, autoincrement=False)
|
||||||
|
|
||||||
|
name = sa.Column('dept_name', sa.String(length=30), nullable=True)
|
||||||
|
|
||||||
|
tax = sa.Column('dept_tax', sa.Boolean(), nullable=True)
|
||||||
|
|
||||||
|
food_stampable = sa.Column('dept_fs', sa.Boolean(), nullable=True)
|
||||||
|
|
||||||
|
limit = sa.Column('dept_limit', sa.Float(), nullable=True)
|
||||||
|
|
||||||
|
minimum = sa.Column('dept_minimum', sa.Float(), nullable=True)
|
||||||
|
|
||||||
|
discount = sa.Column('dept_discount', sa.Boolean(), nullable=True)
|
||||||
|
|
||||||
|
see_id = sa.Column('dept_see_id', sa.SmallInteger(), nullable=True)
|
||||||
|
|
||||||
|
modified = sa.Column(sa.DateTime(), nullable=True)
|
||||||
|
|
||||||
|
modified_by_id = sa.Column('modifiedby', sa.Integer(), nullable=True)
|
||||||
|
|
||||||
|
margin = sa.Column(sa.Float(), nullable=False)
|
||||||
|
|
||||||
|
sales_code = sa.Column('salesCode', sa.Integer(), nullable=False)
|
||||||
|
|
||||||
|
member_only = sa.Column('memberOnly', sa.SmallInteger(), nullable=False)
|
||||||
|
|
||||||
|
line_item_discount = sa.Column(sa.Boolean(), nullable=True)
|
||||||
|
|
||||||
|
wicable = sa.Column('dept_wicable', sa.Boolean(), nullable=True)
|
||||||
|
|
||||||
|
def __str__(self):
|
||||||
|
return self.name or ""
|
||||||
|
|
||||||
|
|
||||||
class Product(Base):
|
class Product(Base):
|
||||||
"""
|
"""
|
||||||
Represents a product, purchased and/or sold by the organization.
|
Represents a product, purchased and/or sold by the organization.
|
||||||
|
|
Loading…
Reference in a new issue