diff --git a/src/sparepart/model.py b/src/sparepart/model.py index ff24267..522a3fc 100644 --- a/src/sparepart/model.py +++ b/src/sparepart/model.py @@ -7,17 +7,17 @@ from src.models import DefaultMixin, IdentityMixin, TimeStampMixin from src.workorder.model import MasterWorkOrder -# class MasterSparePart(Base, DefaultMixin): -# __tablename__ = "oh_ms_sparepart" +class MasterSparePart(Base, DefaultMixin): + __tablename__ = "oh_ms_sparepart" -# assetnum = Column(String, nullable=False) -# location_tag = Column(String, nullable=False) -# stock = Column(Integer, nullable=False, default=0) -# name = Column(String, nullable=False) -# cost_per_stock = Column(Float, nullable=False) -# unit = Column(String, nullable=False) + assetnum = Column(String, nullable=False) + location_tag = Column(String, nullable=False) + stock = Column(Integer, nullable=False, default=0) + name = Column(String, nullable=False) + cost_per_stock = Column(Float, nullable=False) + unit = Column(String, nullable=False) -# sparepart_procurements = relationship("MasterSparepartProcurement", lazy="selectin") + sparepart_procurements = relationship("MasterSparepartProcurement", lazy="selectin") class MasterSparepartProcurement(Base, DefaultMixin):