forked from ScoDoc/ScoDoc
Intégration bulletins html
This commit is contained in:
parent
2220b617b8
commit
a09418329f
@ -822,47 +822,16 @@ def formsemestre_bulletinetud(
|
||||
H = [
|
||||
_formsemestre_bulletinetud_header_html(etud, formsemestre, format, version),
|
||||
bulletin,
|
||||
render_template(
|
||||
"bul_foot.html",
|
||||
etud=etud,
|
||||
formsemestre=formsemestre,
|
||||
inscription_courante=etud.inscription_courante(),
|
||||
inscription_str=etud.inscription_descr()["inscription_str"],
|
||||
),
|
||||
html_sco_header.sco_footer(),
|
||||
]
|
||||
|
||||
H.append("""<p>Situation actuelle: """)
|
||||
inscription_courante = etud.inscription_courante()
|
||||
if inscription_courante:
|
||||
H.append(
|
||||
f"""<a class="stdlink" href="{url_for(
|
||||
"notes.formsemestre_status",
|
||||
scodoc_dept=g.scodoc_dept,
|
||||
formsemestre_id=inscription_courante.formsemestre_id)
|
||||
}">"""
|
||||
)
|
||||
inscription_descr = etud.inscription_descr()
|
||||
H.append(inscription_descr["inscription_str"])
|
||||
if inscription_courante:
|
||||
H.append("""</a>""")
|
||||
H.append("""</p>""")
|
||||
if formsemestre.modalite == "EXT":
|
||||
H.append(
|
||||
f"""<p><a
|
||||
href="{url_for('notes.formsemestre_ext_edit_ue_validations',
|
||||
scodoc_dept=g.scodoc_dept,
|
||||
formsemestre_id=formsemestre_id,
|
||||
etudid=etudid)}"
|
||||
class="stdlink">
|
||||
Éditer les validations d'UE dans ce semestre extérieur
|
||||
</a></p>"""
|
||||
)
|
||||
# Place du diagramme radar
|
||||
H.append(
|
||||
"""<form id="params">
|
||||
<input type="hidden" name="etudid" id="etudid" value="%s"/>
|
||||
<input type="hidden" name="formsemestre_id" id="formsemestre_id" value="%s"/>
|
||||
</form>"""
|
||||
% (etudid, formsemestre_id)
|
||||
)
|
||||
H.append('<div id="radar_bulletin"></div>')
|
||||
|
||||
# --- Pied de page
|
||||
H.append(html_sco_header.sco_footer())
|
||||
|
||||
return "".join(H)
|
||||
|
||||
|
||||
|
@ -1963,7 +1963,18 @@ table.notes_recapcomplet a:hover {
|
||||
div.notes_bulletin {
|
||||
margin-right: 5px;
|
||||
}
|
||||
div.bulletin_menubar {
|
||||
div.bull_head {
|
||||
display: grid;
|
||||
justify-content: space-between;
|
||||
grid-template-columns: auto auto;
|
||||
}
|
||||
div.bull_photo {
|
||||
display: inline-block;
|
||||
margin-right: 10px;
|
||||
}
|
||||
span.bulletin_menubar_but {
|
||||
display: inline-block;
|
||||
margin-left: 2em;
|
||||
margin-right: 2em;
|
||||
}
|
||||
table.notes_bulletin {
|
||||
@ -2105,12 +2116,6 @@ a.bull_link:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
table.bull_head {
|
||||
width: 100%;
|
||||
}
|
||||
td.bull_photo {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
div.bulletin_menubar {
|
||||
padding-left: 25px;
|
||||
|
34
app/templates/bul_foot.html
Normal file
34
app/templates/bul_foot.html
Normal file
@ -0,0 +1,34 @@
|
||||
{# -*- mode: jinja-html -*- #}
|
||||
{# Pied des bulletins HTML #}
|
||||
|
||||
<p>Situation actuelle:
|
||||
{% if inscription_courante %}
|
||||
<a class="stdlink" href="{{url_for(
|
||||
"notes.formsemestre_status",
|
||||
scodoc_dept=g.scodoc_dept,
|
||||
formsemestre_id=inscription_courante.formsemestre_id)
|
||||
}}">{{inscription_str}}</a>
|
||||
{% else %}
|
||||
{{inscription_str}}
|
||||
{% endif %}
|
||||
</p>
|
||||
|
||||
{% if formsemestre.modalite == "EXT" %}
|
||||
<p><a href="{{
|
||||
url_for('notes.formsemestre_ext_edit_ue_validations',
|
||||
scodoc_dept=g.scodoc_dept,
|
||||
formsemestre_id=formsemestre.id,
|
||||
etudid=etud.id)}}"
|
||||
class="stdlink">
|
||||
Éditer les validations d'UE dans ce semestre extérieur
|
||||
</a></p>
|
||||
{% endif %}
|
||||
|
||||
{# Place du diagramme radar #}
|
||||
<form id="params">
|
||||
<input type="hidden" name="etudid" id="etudid" value="{{etud.id}}"/>
|
||||
<input type="hidden" name="formsemestre_id" id="formsemestre_id" value="{{formsemestre.id}}"/>
|
||||
</form>
|
||||
<div id="radar_bulletin"></div>
|
||||
|
||||
|
@ -2,9 +2,8 @@
|
||||
{# L'en-tête des bulletins HTML #}
|
||||
{# was _formsemestre_bulletinetud_header_html #}
|
||||
|
||||
<table class="bull_head">
|
||||
<tr>
|
||||
<td>
|
||||
<div class="bull_head">
|
||||
<div class="bull_head_text">
|
||||
{% if not is_apc %}
|
||||
<h2><a class="discretelink" href="{{
|
||||
url_for(
|
||||
@ -12,34 +11,32 @@
|
||||
)}}">{{etud.nomprenom}}</a></h2>
|
||||
{% endif %}
|
||||
<form name="f" method="GET" action="{{request.base_url}}">
|
||||
Bulletin <span class="bull_liensemestre"><a href="{{
|
||||
<input type="hidden" name="formsemestre_id" value="{{formsemestre.id}}"></input>
|
||||
<input type="hidden" name="etudid" value="{{etud.id}}"></input>
|
||||
<input type="hidden" name="format" value="{{format}}"></input>
|
||||
Bulletin
|
||||
<span class="bull_liensemestre"><a href="{{
|
||||
url_for("notes.formsemestre_status",
|
||||
scodoc_dept=g.scodoc_dept,
|
||||
formsemestre_id=formsemestre.id)}}
|
||||
">{{formsemestre.titre_mois()}}</a></span>
|
||||
<br/>
|
||||
<table>
|
||||
<tr>
|
||||
<td>établi le {{time.strftime("%d/%m/%Y à %Hh%M")}} (notes sur 20)</td>
|
||||
<td><span class="rightjust">
|
||||
<input type="hidden" name="formsemestre_id" value="{{formsemestre.id}}"></input>
|
||||
<input type="hidden" name="etudid" value="{{etud.id}}"></input>
|
||||
<input type="hidden" name="format" value="{{format}}"></input>
|
||||
<select name="version" onchange="document.f.submit()" class="noprint">
|
||||
{% for (v, e) in (
|
||||
("short", "Version courte"),
|
||||
("selectedevals", "Version intermédiaire"),
|
||||
("long", "Version complète"),
|
||||
) %}
|
||||
<option value="{{v}}" {% if (v == version) %}selected{% endif %}>{{e}}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
</td>
|
||||
<td class="bulletin_menubar">
|
||||
<div class="bulletin_menubar">{{menu_autres_operations|safe}}</div>
|
||||
</td>
|
||||
<td><a href="{{url_for(
|
||||
formsemestre_id=formsemestre.id)}}">{{formsemestre.titre_mois()
|
||||
}}</a></span>
|
||||
|
||||
<div>
|
||||
<em>établi le {{time.strftime("%d/%m/%Y à %Hh%M")}} (notes sur 20)</em>
|
||||
<span class="rightjust">
|
||||
<select name="version" onchange="document.f.submit()" class="noprint">
|
||||
{% for (v, e) in (
|
||||
("short", "Version courte"),
|
||||
("selectedevals", "Version intermédiaire"),
|
||||
("long", "Version complète"),
|
||||
) %}
|
||||
<option value="{{v}}" {% if (v == version) %}selected{% endif %}>{{e}}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
<span class="bulletin_menubar">
|
||||
<span class="bulletin_menubar_but">{{menu_autres_operations|safe}}</span>
|
||||
<a href="{{url_for(
|
||||
'notes.formsemestre_bulletinetud',
|
||||
scodoc_dept=g.scodoc_dept,
|
||||
formsemestre_id=formsemestre.id,
|
||||
@ -47,16 +44,14 @@
|
||||
format='pdf',
|
||||
version=version,
|
||||
)}}">{{scu.ICON_PDF|safe}}</a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</span>
|
||||
</div>
|
||||
</form>
|
||||
</td>
|
||||
</div>
|
||||
{% if not is_apc %}
|
||||
<td class="bull_photo"><a href="{{
|
||||
url_for("scolar.ficheEtud", scodoc_dept=g.scodoc_dept, etudid=etud.id)
|
||||
}}">{{etud.photo_html(title="fiche de " + etud["nom"])|safe}}</a>
|
||||
</td>
|
||||
<div class="bull_photo"><a href="{{
|
||||
url_for("scolar.ficheEtud", scodoc_dept=g.scodoc_dept, etudid=etud.id)
|
||||
}}">{{etud.photo_html(title="fiche de " + etud["nom"])|safe}}</a>
|
||||
</div>
|
||||
{% endif %}
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
@ -11,6 +11,9 @@
|
||||
|
||||
<releve-but></releve-but>
|
||||
<script src="/ScoDoc/static/js/releve-but.js"></script>
|
||||
|
||||
{% include 'bul_foot.html' %}
|
||||
|
||||
<script>
|
||||
let dataSrc = "{{bul_url|safe}}";
|
||||
fetch(dataSrc)
|
||||
|
@ -334,6 +334,8 @@ def formsemestre_bulletinetud(
|
||||
),
|
||||
etud=etud,
|
||||
formsemestre=formsemestre,
|
||||
inscription_courante=etud.inscription_courante(),
|
||||
inscription_str=etud.inscription_descr()["inscription_str"],
|
||||
is_apc=formsemestre.formation.is_apc(),
|
||||
menu_autres_operations=sco_bulletins.make_menu_autres_operations(
|
||||
formsemestre, etud, "notes.formsemestre_bulletinetud", version
|
||||
|
Loading…
Reference in New Issue
Block a user