X-Git-Url: http://git.auf.org/?p=auf_rh_dae.git;a=blobdiff_plain;f=project%2Fdae%2Fmodels.py;h=cc0630838d77a385a18435f7e0334660287a2cb7;hp=4098e1db09a182f3aa49d7d2f19b9b2c7057f1d6;hb=e37247dbaefb4daff07861e7500249770efe07bc;hpb=63e0d6b2bf9ae9ac4493e1cbfe84889bea0d9135 diff --git a/project/dae/models.py b/project/dae/models.py index 4098e1d..cc06308 100644 --- a/project/dae/models.py +++ b/project/dae/models.py @@ -76,6 +76,21 @@ class Poste(PosteWorkflow, rh.Poste_): max_digits=12, decimal_places=2, default=0 ) + @property + def total_employe_min(self): + res = ((self.salaire_min or Decimal('0')) + + (self.indemn_fct_min or Decimal('0')) + + (self.indemn_expat_min or Decimal('0')) + ) + return res + + @property + def total_employe_max(self): + return ((self.salaire_max or Decimal('0')) + + (self.indemn_fct_max or Decimal('0')) + + (self.indemn_expat_max or Decimal('0')) + ) + # Managers objects = PosteManager()