1
0
forked from ScoDoc/ScoDoc
ScoDoc-Front/app/templates/configuration.html

95 lines
2.7 KiB
HTML
Raw Permalink Normal View History

2021-12-28 16:17:07 +01:00
{# -*- mode: jinja-html -*- #}
{% extends 'base.html' %}
{% import 'bootstrap/wtf.html' as wtf %}
2021-11-19 11:51:05 +01:00
{% macro render_field(field, with_label=True) %}
<div>
2021-11-19 11:51:05 +01:00
{% if with_label %}
<span class="wtf-field">{{ field.label }} :</span>
{% endif %}
<span class="wtf-field">{{ field(**kwargs)|safe }}
{% if field.errors %}
<ul class=errors>
{% for error in field.errors %}
<li>{{ error }}</li>
{% endfor %}
</ul>
{% endif %}
</span>
</div>
{% endmacro %}
{% block app_content %}
<h1>Configuration générale</h1>
<div class="sco_help greenboldtext">Les paramètres donnés ici s'appliquent à tout ScoDoc (tous les départements).</div>
<section>
<h2>Calcul des "bonus" définis par l'établissement</h2>
<form id="configuration_form" class="sco-form" action="" method="post" enctype="multipart/form-data" novalidate>
{{ form_bonus.hidden_tag() }}
<div class="row">
<div class="col-md-4">
{{ wtf.quick_form(form_bonus) }}
</div>
</div>
2022-01-27 18:12:40 +01:00
<div id="bonus_description"></div>
</form>
</section>
2021-11-16 18:48:56 +01:00
<section>
<h2>Gestion des images: logos, signatures, ...</h2>
<div class="sco_help">Ces images peuvent être intégrées dans les documents
générés par ScoDoc: bulletins, PV, etc.
2021-11-19 11:51:05 +01:00
</div>
<p><a class="stdlink" href="{{url_for('scodoc.configure_logos')}}">configuration des images et logos</a>
</p>
</section>
<section>
<h2>Exports Apogée</h2>
<p><a class="stdlink" href="{{url_for('scodoc.config_codes_decisions')}}">configuration des codes de décision</a></p>
</section>
<h2>Utilisateurs</h2>
<section>
<p><a class="stdlink" href="{{url_for('auth.reset_standard_roles_permissions')}}">remettre
les permissions des rôles standards à leurs valeurs par défaut</a> (efface les modifications apportées)
</p>
</section>
<h2>ScoDoc</h2>
<form id="configuration_form_scodoc" class="sco-form" action="" method="post" enctype="multipart/form-data" novalidate>
{{ form_scodoc.hidden_tag() }}
<div class="row">
<div class="col-md-4">
{{ wtf.quick_form(form_scodoc) }}
</div>
</div>
</form>
{% endblock %}
{% block scripts %}
{{ super() }}
<script>
2022-01-27 18:12:40 +01:00
function update_bonus_description() {
var query = "/ScoDoc/get_bonus_description/" + $("#configuration_form select")[0].value;
$.get(query, '', function (data) {
$("#bonus_description").html(data);
});
}
$(function()
{
$("#configuration_form select").change(function(){
2022-01-27 18:12:40 +01:00
update_bonus_description();
});
2022-01-27 18:12:40 +01:00
update_bonus_description();
});
</script>
{% endblock %}