Newer
Older
from sqlalchemy import Column, Integer, ForeignKey, Boolean
from pilab.database import Base
class SwitchType(Base):
__tablename__ = "switches"
host_id = Column(Integer, ForeignKey('hosts.id'), primary_key=True)
poe = Column(Boolean)
class ControllerType(Base):
__tablename__ = "controllers"
host_id = Column(Integer, ForeignKey('hosts.id'), primary_key=True)