From 55ca50890f7d132bb626811aa9e50cce24d5f996 Mon Sep 17 00:00:00 2001 From: Yannick Francois Date: Fri, 26 Oct 2018 22:07:05 +0200 Subject: [PATCH] Recherche de sondate en deux temps --- public/dates.html | 2 +- public/index.html | 6 +----- public/notifications.html | 4 ++-- public/parametres.html | 2 +- public/recapitulatif.html | 2 +- public/responses-content.html | 37 +++++++++++++++++++++++++++++++++++ public/responses.html | 6 ++++-- public/script.js | 25 +++++++++++++++-------- public/search-poll.html | 33 +++++++++++++++++++++++++++++++ 9 files changed, 97 insertions(+), 20 deletions(-) create mode 100644 public/responses-content.html create mode 100644 public/search-poll.html diff --git a/public/dates.html b/public/dates.html index c24eb5d7..f44a7c3a 100644 --- a/public/dates.html +++ b/public/dates.html @@ -30,7 +30,7 @@ diff --git a/public/index.html b/public/index.html index 837c2b14..15f0b2a9 100644 --- a/public/index.html +++ b/public/index.html @@ -27,11 +27,7 @@

Où sont mes sondages ?

-
- - . - -
+

Vous ne savez plus où sont vos sondages ? C’est par ici que ça se passe !

diff --git a/public/notifications.html b/public/notifications.html index e4807b09..911f7672 100644 --- a/public/notifications.html +++ b/public/notifications.html @@ -70,8 +70,8 @@ diff --git a/public/parametres.html b/public/parametres.html index c6ceb00b..b245230e 100644 --- a/public/parametres.html +++ b/public/parametres.html @@ -35,7 +35,7 @@ diff --git a/public/recapitulatif.html b/public/recapitulatif.html index c664531f..cb7cff4b 100644 --- a/public/recapitulatif.html +++ b/public/recapitulatif.html @@ -49,7 +49,7 @@ diff --git a/public/responses-content.html b/public/responses-content.html new file mode 100644 index 00000000..da9d6056 --- /dev/null +++ b/public/responses-content.html @@ -0,0 +1,37 @@ + + + + + + + + + Framadate + + + + + + + + + + +
+

Les réponses

+ + +
+ + + + + + + + diff --git a/public/responses.html b/public/responses.html index 67ca4abe..23d6bb1b 100644 --- a/public/responses.html +++ b/public/responses.html @@ -28,14 +28,16 @@

diff --git a/public/script.js b/public/script.js index 3e7dc914..09b06067 100644 --- a/public/script.js +++ b/public/script.js @@ -58,16 +58,25 @@ $$('input').forEach((inputElement) => { }); }); -$("#add-response-choice").addEventListener('click', (e) => { - e.preventDefault(); - let response = document.createElement("li"); - let text = document.createTextNode("Blabla"); - response.appendChild(text); +if($("#add-response-choice")) { + $("#add-response-choice").addEventListener('click', (e) => { + e.preventDefault(); + let response = document.createElement("li"); + let text = document.createTextNode("Blabla"); + response.appendChild(text); - $("#responses").appendChild(response); + $("#responses").appendChild(response); + }); +} + +$$(".next").forEach((button) => { + button.addEventListener("click", (e) => { + $$(".toggle-field").forEach((field) => { + localStorage.setItem(field.id, field.innerText); + }); + }); }); - if(document.getElementById("type_sondage")) { type_sondage.addEventListener('change', function() { let typeSondage = this.options[this.selectedIndex].text; @@ -78,7 +87,6 @@ if(document.getElementById("type_sondage")) { localStorage.setItem('type_sondage', 'dates'); $('#next').href = "dates.html"; } - debugStorage() }) } @@ -89,3 +97,4 @@ if(document.getElementById("startButton")) { }); } +debugStorage(); diff --git a/public/search-poll.html b/public/search-poll.html new file mode 100644 index 00000000..cffac5d0 --- /dev/null +++ b/public/search-poll.html @@ -0,0 +1,33 @@ + + + + + + + + Framadate + + + + + + + + + + +
+

Où sont mes sondages ?

+ +
+ +
+
+ + + +