Changement nom+prenom par Stphane.
Si l'adhrent n'a pas de compte ne pose pas de question. Sinon demande si le compte est utilis si oui conserve le login inchang si non dtruit le compte et en cre un nouveau darcs-hash:20051107000653-41617-8638a050728561810634ecd1e09c04917aca9987.gz
This commit is contained in:
parent
2f1b832f50
commit
11c381d8c8
2 changed files with 74 additions and 5 deletions
|
@ -1561,16 +1561,22 @@ class adherent(base_proprietaire):
|
|||
if sre.match('.*crans.(org|ens-cachan.fr)$',new):
|
||||
raise ValueError(u"Adresse mail @crans interdite ici")
|
||||
|
||||
self._set('mail',[new])
|
||||
|
||||
# Il ne doit pas y avoir de compte
|
||||
self.supprimer_compte()
|
||||
self._set('mail',[new])
|
||||
|
||||
return new
|
||||
|
||||
def supprimer_compte(self):
|
||||
u"""
|
||||
Supprime le compte sur zamok. Penser à définir l'adresse mail après.
|
||||
"""
|
||||
self._set('mail', [''])
|
||||
self._data['objectClass'] = [ 'adherent' ]
|
||||
|
||||
|
||||
for c in [ 'uid', 'cn', 'shadowLastChange', 'shadowMax', 'shadowWarning', 'loginShell', 'userPassword', 'uidNumber', 'gidNumber', 'homeDirectory', 'gecos', 'droits','mailAlias', 'cannonicalAlias' ]:
|
||||
try: self._data.pop(c)
|
||||
except: pass
|
||||
|
||||
return new
|
||||
|
||||
def etudes(self,index_or_new):
|
||||
"""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue