mirror of
https://framagit.org/framasoft/framadate/funky-framadate-front.git
synced 2023-08-25 13:53:14 +02:00
affiche les horaires dans un sondage spécial dates
This commit is contained in:
parent
eb79e61611
commit
a5f3e96ad1
@ -2,6 +2,8 @@
|
||||
|
||||
Expérimentation d'une nouvelle façon de faire des sondage.
|
||||
|
||||
https://sketch.cloud/s/MMzYa/dRrDMZ
|
||||
|
||||
## Developpement
|
||||
|
||||
Si docker est disponible sur la machine :
|
||||
|
@ -25,20 +25,49 @@
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<p>Je veux ajouter des dates <select id="ajouterDesHoraires"><option>sans</option><option>avec des</option></select> horaires<span id="identiquesDifferentsPourChaqueJour" style="display:none"> <select><option>identiques</option><option>différents</option></select> pour chaque jour</span>.</p>
|
||||
<p>Je veux ajouter des dates <select id="ajouterDesHoraires"><option>sans</option><option>avec des</option></select> horaires<span id="identiquesDifferentsPourChaqueJour" style="display:none"> <select id="horairesIdentiquesOuDifferents"><option>identiques</option><option>différents</option></select> pour chaque jour</span>.</p>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h1>Mes dates <span>(au format JJ / MM / AAAA)</span></h1>
|
||||
<h1>Les choix <span>(au format JJ / MM / AAAA)</span></h1>
|
||||
<ul>
|
||||
<li>
|
||||
<i class="far fa-calendar-alt"></i>
|
||||
<input type="date" name="date-1">
|
||||
<button class="remove btn-no-style"><i class="fas fa-trash-alt"></i></button>
|
||||
<ul class="horaire-different" style="display:none">
|
||||
<li>
|
||||
<i class="far fa-chrono-alt"></i>
|
||||
<input type="text" name="horaire-1">
|
||||
<button class="remove btn-no-style"><i class="fas fa-trash-alt"></i></button>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<i class="far fa-calendar-alt"></i>
|
||||
<input type="date" name="date-1">
|
||||
<button class="remove btn-no-style"><i class="fas fa-trash-alt"></i></button>
|
||||
<ul class="horaire-different" style="display:none">
|
||||
<li>
|
||||
<i class="far fa-chrono-alt"></i>
|
||||
<input type="text" name="horaire-1">
|
||||
<button class="remove btn-no-style"><i class="fas fa-trash-alt"></i></button>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<button id="addDateButton">Ajouter une date</button>
|
||||
|
||||
<ul class="horaire-identique" style="display:none">
|
||||
<li>
|
||||
<i class="far fa-chrono-alt"></i>
|
||||
<input type="text" name="horaire-1">
|
||||
<button class="remove btn-no-style"><i class="fas fa-trash-alt"></i></button>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
</section>
|
||||
|
||||
<nav>
|
||||
|
@ -120,11 +120,27 @@ if($('#validation-pool-title') && localStorage["title"]) {
|
||||
if($('#ajouterDesHoraires')) {
|
||||
ajouterDesHoraires.addEventListener('change', () => {
|
||||
if (ajouterDesHoraires.value == 'avec des') {
|
||||
console.log("avec des")
|
||||
identiquesDifferentsPourChaqueJour.style.display = 'inline'
|
||||
$('.horaire-identique').style.display = 'inline'
|
||||
} else {
|
||||
console.log("sans")
|
||||
identiquesDifferentsPourChaqueJour.style.display = 'none'
|
||||
$('.horaire-identique').style.display = 'none'
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if($('#horairesIdentiquesOuDifferents')) {
|
||||
horairesIdentiquesOuDifferents.addEventListener('change', () => {
|
||||
if (horairesIdentiquesOuDifferents.value == 'identiques') {
|
||||
$('.horaire-identique').style.display = 'inline'
|
||||
$$('.horaire-different').forEach( (e) => {
|
||||
e.style.display = 'none'
|
||||
});
|
||||
} else {
|
||||
$('.horaire-identique').style.display = 'none'
|
||||
$$('.horaire-different').forEach( (e) => {
|
||||
e.style.display = 'inline'
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user