[proprio.__init__] On ne prend plus de liste de machines à l'initialisation
Ça n'est pas utilisé, et je ne sais pas pourquoi, mais ça initialise self._machine avec objets.machine au lieu de None du coup, je le retire. Je fais de même pour self._clubs et self._imprimeur_clubs par homogénéité.
This commit is contained in:
parent
f069ead1ea
commit
00a8e001e1
1 changed files with 6 additions and 6 deletions
12
objets.py
12
objets.py
|
@ -486,9 +486,9 @@ class proprio(CransLdapObject):
|
||||||
|
|
||||||
attribs = [attributs.nom, attributs.chbre, attributs.paiement, attributs.info, attributs.blacklist, attributs.controle, attributs.historique]
|
attribs = [attributs.nom, attributs.chbre, attributs.paiement, attributs.info, attributs.blacklist, attributs.controle, attributs.historique]
|
||||||
|
|
||||||
def __init__(self, conn, dn, mode='ro', ldif = None, machines=None):
|
def __init__(self, conn, dn, mode='ro', ldif=None):
|
||||||
super(proprio, self).__init__(conn, dn, mode, ldif)
|
super(proprio, self).__init__(conn, dn, mode, ldif)
|
||||||
self._machines = machines
|
self._machines = None
|
||||||
|
|
||||||
def sursis_carte(self):
|
def sursis_carte(self):
|
||||||
for h in self['historique'][::-1]:
|
for h in self['historique'][::-1]:
|
||||||
|
@ -661,11 +661,11 @@ class adherent(proprio):
|
||||||
]
|
]
|
||||||
ldap_name = "adherent"
|
ldap_name = "adherent"
|
||||||
|
|
||||||
def __init__(self, conn, dn, mode='ro', ldif = None, machines=None, clubs=None, imprimeur_clubs=None):
|
def __init__(self, conn, dn, mode='ro', ldif=None):
|
||||||
super(adherent, self).__init__(conn, dn, mode, ldif, machine)
|
super(adherent, self).__init__(conn, dn, mode, ldif)
|
||||||
self.full = False
|
self.full = False
|
||||||
self._clubs = clubs
|
self._clubs = None
|
||||||
self._imprimeur_clubs = imprimeur_clubs
|
self._imprimeur_clubs = None
|
||||||
if u'cransAccount' in [ unicode(o) for o in self['objectClass']]:
|
if u'cransAccount' in [ unicode(o) for o in self['objectClass']]:
|
||||||
self.attribs = self.attribs + crans_account_attribs
|
self.attribs = self.attribs + crans_account_attribs
|
||||||
self.full = True
|
self.full = True
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue