forked from ScoDoc/ScoDoc
wip
This commit is contained in:
parent
a42e23b0ec
commit
ecd48de211
@ -29,19 +29,32 @@
|
|||||||
.then(r => { return r.json(); })
|
.then(r => { return r.json(); })
|
||||||
.then(json => {
|
.then(json => {
|
||||||
let etudiants = json;
|
let etudiants = json;
|
||||||
|
promises_etud_semestres = []
|
||||||
|
promises_semestres = []
|
||||||
etudiants.forEach((etudiant) => {
|
etudiants.forEach((etudiant) => {
|
||||||
let url =`/ScoDoc/{{dept}}/api/etudiant/nip/${etudiant.code_nip}/formsemestres`;
|
let url =`/ScoDoc/{{dept}}/api/etudiant/nip/${etudiant.code_nip}/formsemestres`;
|
||||||
console.log(url);
|
console.log(url);
|
||||||
etudiant.formsemestres_id = [];
|
promises_etud_semestres.push(
|
||||||
fetch(`/ScoDoc/{{dept}}/api/etudiant/nip/${etudiant.code_nip}/formsemestres`)
|
fetch(url)
|
||||||
|
.then(r => { return r.json(); })
|
||||||
|
.then(semestre => {
|
||||||
|
formsemestre_id = semestre.formsemestre_id;
|
||||||
|
|
||||||
|
})
|
||||||
|
)
|
||||||
|
// etudiant.formsemestres_id = [];
|
||||||
|
fetch(url)
|
||||||
.then(r => {return r.json; })
|
.then(r => {return r.json; })
|
||||||
.then(json => {
|
.then(json => {
|
||||||
let forms = json;
|
let forms = json;
|
||||||
forms.forEach((formsem) => {
|
console.log(etudiant.code_nip + " " + forms.formsemestre_id);
|
||||||
if (formsem.is_apc) {
|
// forms.forEach((formsem) => {
|
||||||
etudiant.formsemestres_id.push(formsem.formsemestre_id);
|
// if (formsem.is_apc) {
|
||||||
}
|
// etudiant.formsemestres_id.push(formsem.formsemestre_id);
|
||||||
});
|
// if (formsem.formsemestre_id in_array()) {
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// });
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
//let releve = document.querySelector("releve-but");
|
//let releve = document.querySelector("releve-but");
|
||||||
|
Loading…
Reference in New Issue
Block a user