forked from ScoDoc/ScoDoc
Merge pull request 'Correctif affectations groupes' (#676) from lehmann/ScoDoc-Front:master into master
Reviewed-on: https://scodoc.org/git/ScoDoc/ScoDoc/pulls/676
This commit is contained in:
commit
92e75e11f2
@ -366,6 +366,11 @@ body.editionActivated .filtres .nonEditable .move {
|
||||
/*****************************/
|
||||
/* Zone Etudiants */
|
||||
/*****************************/
|
||||
#zoneChoix summary{
|
||||
margin: 0 0 16px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
#zoneChoix .autoAffectation>a {
|
||||
text-decoration: underline;
|
||||
}
|
||||
@ -383,7 +388,7 @@ body.editionActivated .filtres .nonEditable .move {
|
||||
transform: scale(0.9);
|
||||
}
|
||||
|
||||
#zoneChoix>.autoAffectation {
|
||||
#zoneChoix .autoAffectation {
|
||||
background: #c9c9c9;
|
||||
color: #141414;
|
||||
padding: 4px 8px;
|
||||
@ -391,13 +396,13 @@ body.editionActivated .filtres .nonEditable .move {
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
#zoneChoix>.autoAffectation>select {
|
||||
#zoneChoix .autoAffectation>select {
|
||||
border: none;
|
||||
padding: 4px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
#zoneChoix>.autoAffectation>.affectationGo {
|
||||
#zoneChoix .autoAffectation>.affectationGo {
|
||||
display: inline-block;
|
||||
background: #0c9;
|
||||
padding: 8px 16px;
|
||||
|
@ -22,30 +22,34 @@
|
||||
|
||||
<section id="zoneChoix">
|
||||
<h2>Étudiants</h2>
|
||||
<div class="autoAffectation">
|
||||
<a href="students_groups_auto_assignment?formsemestre_id={{formsemestre.id}}"><svg
|
||||
xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none"
|
||||
stroke="#0b0b0b" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path d="M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4M10 17l5-5-5-5M13.8 12H3" />
|
||||
</svg> Aide à l'affectation dans les parcours</a>
|
||||
<div>Importer les résultats :
|
||||
<form class=dropZone>
|
||||
<div>
|
||||
Déposez le fichier .xlsx ou <br>
|
||||
<label>
|
||||
<input type=file accept="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet">
|
||||
</label>
|
||||
</div>
|
||||
</form>
|
||||
<details>
|
||||
<summary>Outils d'affections</summary>
|
||||
<div class="autoAffectation">
|
||||
<a href="students_groups_auto_assignment?formsemestre_id={{formsemestre.id}}"><svg
|
||||
xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none"
|
||||
stroke="#0b0b0b" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path d="M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4M10 17l5-5-5-5M13.8 12H3" />
|
||||
</svg> Aide à l'affectation dans les parcours</a>
|
||||
<div>Importer les résultats :
|
||||
<form class=dropZone>
|
||||
<div>
|
||||
Déposez le fichier .xlsx ou <br>
|
||||
<label>
|
||||
<input type=file accept="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet">
|
||||
</label>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="autoAffectation">
|
||||
Affecter automatiquement les étudiants du groupe<br>
|
||||
<select name="affectationFrom" id="affectationFrom"></select>
|
||||
vers le groupe
|
||||
<select name="affectationTo" id="affectationTo"></select>
|
||||
<div class="affectationGo">Valider</div>
|
||||
</div>
|
||||
<div class="autoAffectation">
|
||||
Affecter automatiquement les étudiants du groupe<br>
|
||||
<select name="affectationFrom" id="affectationFrom"></select>
|
||||
vers le groupe
|
||||
<select name="affectationTo" id="affectationTo"></select>
|
||||
<div class="affectationGo">Valider</div>
|
||||
</div>
|
||||
</details>
|
||||
|
||||
<div class="etudiants"></div>
|
||||
</section>
|
||||
|
||||
|
@ -375,7 +375,7 @@
|
||||
Object.values(partition.groups).forEach(group => {
|
||||
parcours[group.id] = {
|
||||
nom: group.group_name,
|
||||
places: savedData.parcours[group.id].places || 28,
|
||||
places: savedData.parcours?.[group.id].places || 28,
|
||||
etudiants: [] // Résultat du tri
|
||||
}
|
||||
})
|
||||
@ -435,17 +435,19 @@
|
||||
}
|
||||
},*/
|
||||
etudiantsRaw.forEach(etudiant => {
|
||||
saved = savedData.etudiants['id' + etudiant.id];
|
||||
saved = savedData.etudiants?.['id' + etudiant.id] || {};
|
||||
etudiants['id' + etudiant.id] = {
|
||||
actif: saved.actif ? true : false,
|
||||
actif: saved.actif == false ? false : true,
|
||||
nom: etudiant.nom + " " + etudiant.prenom,
|
||||
criteres: saved.criteres || {},
|
||||
voeux: saved.voeux || {}
|
||||
};
|
||||
/*Object.keys(parcours).forEach((idParcours, index) => {
|
||||
etudiants['id' + etudiant.id].criteres[idParcours] = 10;
|
||||
etudiants['id' + etudiant.id].voeux[idParcours] = index + 1;
|
||||
})*/
|
||||
|
||||
if (Object.keys(saved).length == 0)
|
||||
Object.keys(parcours).forEach((idParcours, index) => {
|
||||
etudiants['id' + etudiant.id].criteres[idParcours] = 10;
|
||||
etudiants['id' + etudiant.id].voeux[idParcours] = index + 1;
|
||||
})
|
||||
})
|
||||
|
||||
/* Zone étudiants */
|
||||
|
Loading…
Reference in New Issue
Block a user