gest_crans: s'adapte à dialog (plus de '\n')
Désormais dialog semble renvoyer des listes de chaînes déjà strippées.
This commit is contained in:
parent
33fe1b91db
commit
2af454a72b
1 changed files with 5 additions and 5 deletions
|
@ -688,7 +688,7 @@ def set_actif(adher):
|
||||||
if annul: return 1
|
if annul: return 1
|
||||||
|
|
||||||
# Traitement
|
# Traitement
|
||||||
if '1\n' in result:
|
if '1' in result:
|
||||||
adher.active(False)
|
adher.active(False)
|
||||||
else:
|
else:
|
||||||
adher.active(True)
|
adher.active(True)
|
||||||
|
@ -1025,7 +1025,7 @@ def set_vente(proprio):
|
||||||
f = Facture(proprio)
|
f = Facture(proprio)
|
||||||
# Traitement
|
# Traitement
|
||||||
for key in items.keys():
|
for key in items.keys():
|
||||||
if '%s\n' % key in result:
|
if key in result:
|
||||||
while 1:
|
while 1:
|
||||||
if items[key]['pu'] != '*':
|
if items[key]['pu'] != '*':
|
||||||
arg = u'--title "Nombre de %s ?" ' % items[key]['designation']
|
arg = u'--title "Nombre de %s ?" ' % items[key]['designation']
|
||||||
|
@ -1358,17 +1358,17 @@ def set_admin(proprio):
|
||||||
|
|
||||||
# Traitement
|
# Traitement
|
||||||
if has_card:
|
if has_card:
|
||||||
if '1\n' in result:
|
if '1' in result:
|
||||||
proprio.carteEtudiant(True)
|
proprio.carteEtudiant(True)
|
||||||
elif iscontroleur or carte_ok == 'off':
|
elif iscontroleur or carte_ok == 'off':
|
||||||
proprio.carteEtudiant(False)
|
proprio.carteEtudiant(False)
|
||||||
if '2\n' in result:
|
if '2' in result:
|
||||||
proprio.controle('+c')
|
proprio.controle('+c')
|
||||||
else:
|
else:
|
||||||
proprio.controle('-c')
|
proprio.controle('-c')
|
||||||
|
|
||||||
if has_card:
|
if has_card:
|
||||||
if '3\n' in result:
|
if '3' in result:
|
||||||
proprio.charteMA(True)
|
proprio.charteMA(True)
|
||||||
elif isadm or isbureau:
|
elif isadm or isbureau:
|
||||||
proprio.charteMA(False)
|
proprio.charteMA(False)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue