| 36 | |
| 37 | |
| 38 | class Grunt(Employee): |
| 39 | __tablename__ = "grunt" |
| 40 | |
| 41 | id = Column(Integer, ForeignKey("employee.id"), primary_key=True) |
| 42 | savings = Column(Numeric) |
| 43 | |
| 44 | employer_id = Column(Integer, ForeignKey("boss.id")) |
| 45 | |
| 46 | employer = relationship( |
| 47 | "Boss", backref="employees", primaryjoin=Boss.id == employer_id |
| 48 | ) |
| 49 | |
| 50 | __mapper_args__ = {"polymorphic_identity": "grunt"} |
| 51 | |
| 52 | |
| 53 | if os.path.exists("orm2010.db"): |
no test coverage detected