diff --git a/gestion/gest_crans.py b/gestion/gest_crans.py index 1f620611..2e02976f 100755 --- a/gestion/gest_crans.py +++ b/gestion/gest_crans.py @@ -946,6 +946,7 @@ def set_admin(proprio): caution = on_off('k' in proprio.controle()) paiement_ok = on_off('p' in proprio.controle()) carte_ok = on_off('c' in proprio.controle()) + charte_MA = on_off(proprio.charteMA()) # Construction de la boîte de dialogue texte = [] @@ -973,12 +974,16 @@ def set_admin(proprio): if has_card: checklist.append(u'"4" "Carte d\'étudiant vérifiée" "%s"' % carte_ok) checklist.append(u'"5" "Cotisation/charte/caution vérifées" "%s"' % paiement_ok) - + + if isbureau or isadm: + checklist.append(u'"6" "Charte des MA signee" "%s"' % charte_MA) + if not checklist: # Il n'y a rien de modifiable dialog(u'--title "État administratif de %s non modifiable" --msgbox "%s\n" 0 0 ' % (proprio.Nom(), '\n'.join(texte))) return + # Il y a qqch de modifiable, on construit la checklist arg = u'--title "Etat administratif de %s" ' % proprio.Nom() @@ -1033,6 +1038,11 @@ def set_admin(proprio): elif iscontroleur: proprio.controle('-p') + if '6\n' in result: + proprio.charteMA(True) + elif isadm or isbureau: + proprio.charteMA(False) + if 'C\n' in result: proprio.controle('+k') if not iscontroleur: @@ -1462,7 +1472,7 @@ def modif_adher(adher): arg += u'"Blackliste" "Modifier la blackliste de cet adhérent" ' if isimprimeur: arg += u'"Solde" "Effectuer un débit/crédit pour cet adhérent" ' - + annul, res = dialog(arg) if annul: return 1 @@ -1482,6 +1492,8 @@ def modif_adher(adher): set_droits(adher) elif res[0] == 'Blackliste': set_blackliste(adher) + elif res[0] == 'Charte des MA' : + set_charte_MA(adher) elif res[0] == 'Adresse' or res[0] == 'Chambre': arg = u'--title "Déménagement de %s" ' % adher.Nom() arg += u'--menu "Question :" 0 0 0 '