Exemplo n.º 1
0
class Picture(db.Model):
    """
    Images should be in the static directory
    """
    id = db.Column(db.Integer, primary_key=True)
    file_name = db.Column(db.String(255))
    thumb_name = db.Column(db.String(255))
Exemplo n.º 2
0
class Event(db.Model):
    """
    A record for each auction event (day)
    """
    id = db.Column(db.Integer, primary_key=True)
    description = db.Column(db.String(255))
    date = db.Column(db.Integer)
    status = db.Column(db.Integer)
    auctions = db.relationship('Auction', backref='event', lazy=True)
Exemplo n.º 3
0
class Item(db.Model):
    """
    List of items for auction
    """
    id = db.Column(db.Integer, primary_key=True)
    event_id = db.Column(db.Integer)
    auction_id = db.Column(db.Integer)
    donor_id = db.Column(db.Integer)
    last_bid_id = db.Column(db.Integer)
    description = db.Column(db.String(255))
    value = db.Column(db.Float)
    price = db.Column(db.Float)
    reserve = db.Column(db.Float)
    is_sold = db.Column(db.Boolean)
Exemplo n.º 4
0
class Organization(db.Model):
    """
    Organization information - single row
    """
    id = db.Column(db.Integer, primary_key=True)
    name = db.Column(db.String(255))
    address1 = db.Column(db.String(255))
    address2 = db.Column(db.String(255))
    city = db.Column(db.String(255))
    state = db.Column(db.String(255))
    postal_code = db.Column(db.String(255))
    telephone = db.Column(db.String(255))
    email_address = db.Column(db.String(255))
    logo_image = db.Column(db.Integer)
class AuctionDetails(db.Model):
    AuctionID = db.Column(db.String, primary_key=True)
    PropertyID = db.Column(db.String, unique=True, nullable=False)
    SellerID = db.Column(db.Integer, nullable=False)
    AuctionStart = db.Column(db.DateTime, nullable=False)
    AuctionEnd = db.Column(db.DateTime, nullable=False)
    ReservePrice = db.Column(db.Float, nullable=False)
    MinBiddingGap = db.Column(db.Float, nullable=False)

    def __repr__(self):
        return f"AuctionDetails('{self.AuctionID}', '{self.PropertyID}', '{self.SellerID}')"
Exemplo n.º 6
0
class Auction(db.Model):
    """
    Smaller units of auction (i.e. individual silent auctions and live auctions)
    """
    id = db.Column(db.Integer, primary_key=True)
    event_id = db.Column(db.Integer, db.ForeignKey('event.id'))
    status = db.Column(db.Integer)
    type = db.Column(db.Integer)
    name = db.Column(db.String(255))
    picture_id = db.Column(db.Integer)
Exemplo n.º 7
0
class User(UserMixin, db.Model):
    id = db.Column(db.Integer, primary_key=True)
    last_name = db.Column(db.String(255))
    first_name = db.Column(db.String(255))
    title = db.Column(db.String(255))
    address1 = db.Column(db.String(255))
    address2 = db.Column(db.String(255))
    city = db.Column(db.String(255))
    state = db.Column(db.String(255))
    postal_code = db.Column(db.String(255))
    telephone = db.Column(db.String(255))
    telephone_ext = db.Column(db.String(255))
    email_address = db.Column(db.String(255))
    username = db.Column(db.String(255), unique=True)
    password = db.Column(db.String(255), nullable=False)
    active = db.Column(db.Boolean(), nullable=False, server_default='0')
Exemplo n.º 8
0
class Contact(db.Model):
    id = db.Column(db.Integer, primary_key=True)
    last_name = db.Column(db.String(255))
    first_name = db.Column(db.String(255))
    title = db.Column(db.String(255))
    address1 = db.Column(db.String(255))
    address2 = db.Column(db.String(255))
    city = db.Column(db.String(255))
    state = db.Column(db.String(255))
    postal_code = db.Column(db.String(255))
    telephone = db.Column(db.String(255))
    telephone_ext = db.Column(db.String(255))
    email_address = db.Column(db.String(255))
Exemplo n.º 9
0
class Volunteer(db.Model):
    id = db.Column(db.Integer, primary_key=True)
    last_name = db.Column(db.String(255))
    first_name = db.Column(db.String(255))
    title = db.Column(db.String(255))
    address1 = db.Column(db.String(255))
    address2 = db.Column(db.String(255))
    city = db.Column(db.String(255))
    state = db.Column(db.String(255))
    postal_code = db.Column(db.String(255))
    telephone = db.Column(db.String(255))
    telephone_ext = db.Column(db.String(255))
    email_address = db.Column(db.String(255))
    event_id = db.Column(db.Integer, db.ForeignKey('event.id'))
Exemplo n.º 10
0
class Donor(db.Model):
    id = db.Column(db.Integer, primary_key=True)
    last_name = db.Column(db.String(255))
    first_name = db.Column(db.String(255))
    title = db.Column(db.String(255))
    address1 = db.Column(db.String(255))
    address2 = db.Column(db.String(255))
    city = db.Column(db.String(255))
    state = db.Column(db.String(255))
    postal_code = db.Column(db.String(255))
    telephone = db.Column(db.String(255))
    telephone_ext = db.Column(db.String(255))
    email_address = db.Column(db.String(255))
    is_business = db.Column(db.Boolean)
    is_prospect = db.Column(db.Boolean)
    is_donor = db.Column(db.Boolean)
    business_name = db.Column(db.String(255))