From ec3834fb012a5ad133d5f32da96fd045c7849ab8 Mon Sep 17 00:00:00 2001 From: Alexis POYEN <punkylibre@localhost.localdomain> Date: Tue, 7 Jul 2020 13:32:28 +0200 Subject: [PATCH] Fix : hide areas on election deletion --- web/components/management/election.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/web/components/management/election.js b/web/components/management/election.js index 17b5a3b..c316b22 100644 --- a/web/components/management/election.js +++ b/web/components/management/election.js @@ -243,7 +243,10 @@ class Election { electionTemplate(election) { return /* HTML */ `<div class="card card-list"> - <div id="elections-election-${election.ID}" class="card-content clickable"> + <div + id="elections-election-${election.ID}" + class="card-content clickable" + > <div class="content"> <nav class="level"> <div class="level-left"> @@ -342,9 +345,8 @@ class Election { this.parent.areaHandler.emptyAreas(); this.parent.sectionHandler.emptySections(); this.parent.deskHandler.emptyDesks(); - document.getElementById("desk-new").setAttribute("disabled", "true"); - document.getElementById("section-new").setAttribute("disabled", "true"); - document.getElementById("area-new").setAttribute("disabled", "true"); + document.getElementById("areas").style.display = "none"; + } cloneElection(election) { -- GitLab