Beispiel #1
0
class Position(Field):

    __tablename__ = 'position'
    id = db.Column(db.ForeignKey("field.id"), primary_key=True)
    x = Column(db.Numeric(), default=0)
    y = Column(db.Numeric(), default=0)
    z = Column(db.Numeric(), default=0)
    w = Column(db.Numeric(), default=1)

    __mapper_args__ = {"polymorphic_identity": "position"}
Beispiel #2
0
class Number(Field):

    __tablename__ = 'number'
    id = Column(db.ForeignKey("field.id"), primary_key=True)
    value = Column(db.Numeric())

    __mapper_args__ = {"polymorphic_identity": "number"}