Commit 719e1215 by Administrator

Merge branch 'dev_cooperatic' into '5266-ajout-colonne-rattrapage-choisis'

# Conflicts:
#   members/static/js/admin/manage_makeups.js
parents c3c4790a 2751827f
Pipeline #3136 failed with stage
in 1 minute 7 seconds
...@@ -321,9 +321,11 @@ def admin(request): ...@@ -321,9 +321,11 @@ def admin(request):
def manage_makeups(request): def manage_makeups(request):
""" Administration des membres """ """ Administration des membres """
template = loader.get_template('members/admin/manage_makeups.html') template = loader.get_template('members/admin/manage_makeups.html')
committees_shift_id = CagetteServices.get_committees_shift_id()
m = CagetteMembersSpace() m = CagetteMembersSpace()
context = {'title': 'BDM - Rattrapages', context = {'title': 'BDM - Rattrapages',
'module': 'Membres', 'module': 'Membres',
'has_committe_shift': committees_shift_id is not None,
'extension_duration': m.get_extension_duration() 'extension_duration': m.get_extension_duration()
} }
return HttpResponse(template.render(context, request)) return HttpResponse(template.render(context, request))
......
...@@ -43,8 +43,8 @@ function display_makeups_members() { ...@@ -43,8 +43,8 @@ function display_makeups_members() {
// Remove members with 0 makeups to do // Remove members with 0 makeups to do
ids_to_remove = []; ids_to_remove = [];
for (member_item of makeups_members) { for (let member_item of makeups_members) {
if (member_item.makeups_to_do == 0) { if (member_item.makeups_to_do === 0) {
ids_to_remove.push(member_item.id); ids_to_remove.push(member_item.id);
} }
} }
...@@ -88,6 +88,19 @@ function display_makeups_members() { ...@@ -88,6 +88,19 @@ function display_makeups_members() {
} }
}, },
{ {
data: "shift_type",
title: "<div class='title_center'>Type de créneau</div>",
className: "dt-body-center",
width: "5%",
render: function (data) {
if (data == 'ftop') {
return (has_committe_shift === "True") ? "Comités" : "Volant";
} else {
return 'ABCD';
}
}
},
{
data: "makeups_to_come", data: "makeups_to_come",
title: "<div class='title_center' title=\"Services de rattrapage à venir déjà choisis depuis l'espace membre.\">Rattrapages à venir déjà choisis</div>", title: "<div class='title_center' title=\"Services de rattrapage à venir déjà choisis depuis l'espace membre.\">Rattrapages à venir déjà choisis</div>",
className: "dt-body-center", className: "dt-body-center",
...@@ -112,7 +125,7 @@ function display_makeups_members() { ...@@ -112,7 +125,7 @@ function display_makeups_members() {
} }
}, },
{ {
data: "shift_type", data: null,
title: "<div class='title_center' title=\"Information d'interprétation délicate réservée aux utilisateurs avancés.\">Points (avancé)</div>", title: "<div class='title_center' title=\"Information d'interprétation délicate réservée aux utilisateurs avancés.\">Points (avancé)</div>",
className: "dt-body-center", className: "dt-body-center",
width: "5%", width: "5%",
......
...@@ -85,6 +85,7 @@ ...@@ -85,6 +85,7 @@
<script src='{% static "js/all_common.js" %}?v=1651853225'></script> <script src='{% static "js/all_common.js" %}?v=1651853225'></script>
<script src='{% static "js/admin/manage_makeups.js" %}?v=1651853225'></script> <script src='{% static "js/admin/manage_makeups.js" %}?v=1651853225'></script>
<script> <script>
var has_committe_shift = '{{has_committe_shift}}'
const extension_duration = {{extension_duration}}; const extension_duration = {{extension_duration}};
</script> </script>
{% endblock %} {% endblock %}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment