[ldap_crans] Robustesse du câblage automatique
darcs-hash:20100901131248-ffbb2-2738110e1e430ff40e96bc1de206f3f868035a23.gz
This commit is contained in:
parent
12a275f273
commit
16b4e7a8bf
1 changed files with 15 additions and 2 deletions
|
@ -1759,8 +1759,21 @@ class BaseProprietaire(BaseClasseCrans):
|
|||
if r == 'O' or r == 'o':
|
||||
annuaires.crous_to_crans(bat, ch)
|
||||
else:
|
||||
while True:
|
||||
new_ch = prompt(u"Chambre de l'adhérent ?")
|
||||
try:
|
||||
self.chbre(new_ch)
|
||||
except ValueError, c:
|
||||
if len(c.args) == 2:
|
||||
old_adh = c.args[1]
|
||||
r = prompt(u"Changer %s de chambre ? [O/N]" % old_adh.Nom(), "n")
|
||||
if r == 'o' or r == 'o':
|
||||
old_adh.chbre('????')
|
||||
old_adh.save()
|
||||
self.chbre(new_ch)
|
||||
break
|
||||
else:
|
||||
break
|
||||
|
||||
# Enregistrement
|
||||
self._save()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue