Cache lien 'effacer des décisions de jury' quand on a pas le droit
This commit is contained in:
parent
90c71ebfa4
commit
69af0b9778
@ -2334,7 +2334,7 @@ def formsemestre_validation_but(
|
|||||||
etud = Identite.get_etud(etudid)
|
etud = Identite.get_etud(etudid)
|
||||||
nb_etuds = formsemestre.etuds.count()
|
nb_etuds = formsemestre.etuds.count()
|
||||||
read_only = not formsemestre.can_edit_jury()
|
read_only = not formsemestre.can_edit_jury()
|
||||||
|
can_erase = current_user.has_permission(Permission.EtudInscrit)
|
||||||
# --- Navigation
|
# --- Navigation
|
||||||
prev_lnk = (
|
prev_lnk = (
|
||||||
f"""{scu.EMO_PREV_ARROW} <a href="{url_for(
|
f"""{scu.EMO_PREV_ARROW} <a href="{url_for(
|
||||||
@ -2551,11 +2551,14 @@ def formsemestre_validation_but(
|
|||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
erase_span = f"""
|
erase_span = f"""
|
||||||
<a style="margin-left: 16px;" class="stdlink"
|
<a style="margin-left: 16px;" class="stdlink {'' if can_erase else 'link_unauthorized'}"
|
||||||
|
title="{'' if can_erase else 'réservé au responsable'}"
|
||||||
href="{
|
href="{
|
||||||
url_for("notes.erase_decisions_annee_formation",
|
url_for("notes.erase_decisions_annee_formation",
|
||||||
scodoc_dept=g.scodoc_dept, formation_id=deca.formsemestre.formation.id,
|
scodoc_dept=g.scodoc_dept, formation_id=deca.formsemestre.formation.id,
|
||||||
etudid=deca.etud.id, annee=deca.annee_but, formsemestre_id=formsemestre_id)}"
|
etudid=deca.etud.id, annee=deca.annee_but, formsemestre_id=formsemestre_id)
|
||||||
|
if can_erase else ''
|
||||||
|
}"
|
||||||
>effacer des décisions de jury</a>
|
>effacer des décisions de jury</a>
|
||||||
|
|
||||||
<a style="margin-left: 16px;" class="stdlink"
|
<a style="margin-left: 16px;" class="stdlink"
|
||||||
|
Loading…
Reference in New Issue
Block a user