En mode bref affiche deux colonnes, une pour adhésion et une pour connexion.
This commit is contained in:
parent
1353f00e17
commit
4a3434847e
2 changed files with 49 additions and 20 deletions
15
objets.py
15
objets.py
|
@ -1054,6 +1054,17 @@ class proprio(CransLdapObject):
|
|||
if facture.get('controle', [''])[0] != u"FALSE" and facture.get('recuPaiement', [''])[0] != ''
|
||||
] + [0.0])
|
||||
|
||||
def adhesion_ok(self, no_bl=False):
|
||||
"""Renvoie si le propriétaire a une adhésion en cours."""
|
||||
if self.dn == variables.base_dn:
|
||||
return True
|
||||
|
||||
fin_paiement = self.fin_adhesion()
|
||||
|
||||
paiement = time.time() < fin_paiement or (config.periode_transitoire and config.debut_periode_transitoire <= fin_paiement <= config.fin_periode_transitoire)
|
||||
|
||||
return paiement
|
||||
|
||||
def paiement_ok(self, no_bl=False):
|
||||
u"""
|
||||
Renvoie si le propriétaire a payé pour l'année en cours, en prenant en compte les périodes de transition et les blacklistes.
|
||||
|
@ -1061,15 +1072,19 @@ class proprio(CransLdapObject):
|
|||
"""
|
||||
if self.dn == variables.base_dn:
|
||||
return True
|
||||
|
||||
if not no_bl:
|
||||
for bl in self.blacklist_actif():
|
||||
if bl['type'] == 'paiement':
|
||||
return False
|
||||
|
||||
if isinstance(self, adherent):
|
||||
fin_paiement = min(self.fin_adhesion(), self.fin_connexion())
|
||||
else:
|
||||
fin_paiement = self.fin_adhesion()
|
||||
|
||||
paiement = time.time() < fin_paiement or (config.periode_transitoire and config.debut_periode_transitoire <= fin_paiement <= config.fin_periode_transitoire)
|
||||
|
||||
return paiement
|
||||
|
||||
def carte_ok(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue