forked from ScoDoc/ScoDoc
Merge pull request 'Partition editor : corrections bugs' (#461) from lehmann/ScoDoc-Front:master into master
Reviewed-on: https://scodoc.org/git/ScoDoc/ScoDoc/pulls/461
This commit is contained in:
commit
c9a6fe0743
@ -37,7 +37,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.edition{
|
.edition {
|
||||||
background: #ddd;
|
background: #ddd;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
padding: 8px 32px 8px 8px;
|
padding: 8px 32px 8px 8px;
|
||||||
|
@ -328,7 +328,7 @@
|
|||||||
var url = `/ScoDoc/api/partition/${this.parentElement.dataset.idpartition}/group/create`;
|
var url = `/ScoDoc/api/partition/${this.parentElement.dataset.idpartition}/group/create`;
|
||||||
var payload = { group_name: name };
|
var payload = { group_name: name };
|
||||||
}
|
}
|
||||||
let div = document.createElement("div");
|
var div = document.createElement("div");
|
||||||
div.innerHTML = `
|
div.innerHTML = `
|
||||||
<span class="editing move">||</span>
|
<span class="editing move">||</span>
|
||||||
<span>${name}</span>
|
<span>${name}</span>
|
||||||
@ -361,7 +361,7 @@
|
|||||||
div.dataset.idpartition = r.id;
|
div.dataset.idpartition = r.id;
|
||||||
|
|
||||||
// Ajout dans la zone masques
|
// Ajout dans la zone masques
|
||||||
let div = document.createElement("div");
|
div = document.createElement("div");
|
||||||
div.dataset.idpartition = r.id;
|
div.dataset.idpartition = r.id;
|
||||||
div.innerHTML = `
|
div.innerHTML = `
|
||||||
<div data-idpartition="${r.id}" data-idgroupe=aucun>Non affectés - ${name}</div>
|
<div data-idpartition="${r.id}" data-idgroupe=aucun>Non affectés - ${name}</div>
|
||||||
@ -418,7 +418,7 @@
|
|||||||
document.querySelectorAll(`#zoneChoix .etudiants [data-idpartition="${idpartition}"]`).forEach(e => {
|
document.querySelectorAll(`#zoneChoix .etudiants [data-idpartition="${idpartition}"]`).forEach(e => {
|
||||||
let etudid = e.parentElement.parentElement.dataset.etudid;
|
let etudid = e.parentElement.parentElement.dataset.etudid;
|
||||||
let label = document.createElement("label");
|
let label = document.createElement("label");
|
||||||
label.innerHTML = `<input type=radio name="${idPartition}-${etudiant.etudid}" value="${r.id}"><span>${name}</span>`;
|
label.innerHTML = `<input type=radio name="${idpartition}-${etudid}" value="${r.id}"><span>${name}</span>`;
|
||||||
label.querySelector("input").addEventListener("input", assignment);
|
label.querySelector("input").addEventListener("input", assignment);
|
||||||
e.appendChild(label);
|
e.appendChild(label);
|
||||||
})
|
})
|
||||||
@ -474,7 +474,7 @@
|
|||||||
var payload = { group_name: obj.innerText }
|
var payload = { group_name: obj.innerText }
|
||||||
|
|
||||||
document.querySelectorAll(`#zoneChoix .etudiants [value="${obj.parentElement.dataset.idgroupe}"]+span`).forEach(e => { e.innerText = obj.innerText });
|
document.querySelectorAll(`#zoneChoix .etudiants [value="${obj.parentElement.dataset.idgroupe}"]+span`).forEach(e => { e.innerText = obj.innerText });
|
||||||
document.querySelector(`#zoneGroupes [value="${obj.parentElement.dataset.idgroupe}"]>div`).innerText = obj.innerText;
|
document.querySelector(`#zoneGroupes [data-idgroupe="${obj.parentElement.dataset.idgroupe}"]>div`).innerText = obj.innerText;
|
||||||
}
|
}
|
||||||
|
|
||||||
fetch(url,
|
fetch(url,
|
||||||
|
Loading…
Reference in New Issue
Block a user