button toggle show all
This commit is contained in:
parent
1e02b7062d
commit
14f28ef405
2 changed files with 30 additions and 0 deletions
|
@ -34,5 +34,21 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||||
bodyLanding.style.backgroundColor = randombg;
|
bodyLanding.style.backgroundColor = randombg;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Gestion du bouton pour afficher tous les champs
|
||||||
|
const btnShowAllFields = document.querySelector('#showAllFields');
|
||||||
|
if (btnShowAllFields) {
|
||||||
|
console.log('btnShowAllFields détecté');
|
||||||
|
btnShowAllFields.addEventListener('click', () => {
|
||||||
|
// Sélectionner tous les inputs dans le formulaire
|
||||||
|
const form = document.querySelector('form');
|
||||||
|
if (form) {
|
||||||
|
const hiddenInputs = form.querySelectorAll('.d-none');
|
||||||
|
hiddenInputs.forEach(input => {
|
||||||
|
input.classList.toggle('d-none');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -88,7 +88,21 @@
|
||||||
{{ 'display.submit'|trans }}
|
{{ 'display.submit'|trans }}
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
<hr>
|
||||||
|
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
|
<div class="actions-modification">
|
||||||
|
<button id="showAllFields" class="btn btn-secondary mx-4">
|
||||||
|
<i class="bi bi-eye"></i>
|
||||||
|
Voir aussi les champs déjà remplis
|
||||||
|
</button>
|
||||||
|
|
||||||
|
<button id="closedCommerce" class="btn btn-danger mx-4">
|
||||||
|
<i class="bi bi-x-circle"></i>
|
||||||
|
Je souhaite signaler que ce commerce est fermé
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue