Enregistrement des coefs quand on quitte le formulaire

This commit is contained in:
Emmanuel Viennet 2021-12-11 18:52:43 +01:00
parent 1e96d72ab1
commit fea2078201

View File

@ -43,6 +43,14 @@ function installListeners() {
document.querySelectorAll("[data-editable=true]").forEach(cellule => {
cellule.addEventListener("click", function () { selectCell(this) });
cellule.addEventListener("dblclick", function () { modifCell(this) });
cellule.addEventListener("blur", function () {
let currentModif = document.querySelector(".modifying");
if (currentModif) {
if (!save(currentModif)) {
return;
}
}
});
});
}