Merge pull request #887 from dod-ccpo/to-review

TO Review Page
This commit is contained in:
George Drummond
2019-06-12 11:28:15 -04:00
committed by GitHub
5 changed files with 102 additions and 41 deletions

View File

@@ -28,6 +28,15 @@ class CLIN(Base, mixins.TimestampsMixin):
obligated_amount = Column(Numeric(scale=2), nullable=False)
jedi_clin_type = Column(SQLAEnum(JEDICLINType, native_enum=False), nullable=False)
#
# NOTE: For now obligated CLINS are CLIN 1 + CLIN 3
#
def is_obligated(self):
return self.jedi_clin_type in [
JEDICLINType.JEDI_CLIN_1,
JEDICLINType.JEDI_CLIN_3,
]
def to_dictionary(self):
return {
c.name: getattr(self, c.name)