Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Suivi usager] Désactivation du bouton du formulaire lors de l'envoi #1127

Merged
merged 1 commit into from
Apr 3, 2023

Conversation

emilschn
Copy link
Collaborator

Ticket

#1074

Description

Désactivation du bouton du formulaire sur la page de suivi usager lors de la validation du formulaire, pour éviter des envois en doublon.

Changements apportés

  • Création d'un fichier générique JS qui peut être réutilisée sur d'autres formulaires au besoin (en injectant le JS)

Tests

Conditions de test : utiliser le mode de limitation de réseau du navigateur pour avoir le temps de voir

  • Vérifier que le bouton passe bien en désactivé lors de la soumission du formulaire
  • Vérifier que le bouton reste actif si il y a une erreur dans le formulaire

@sonarcloud
Copy link

sonarcloud bot commented Mar 31, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@github-advanced-security
Copy link

You have successfully added a new SonarCloud configuration ``. As part of the setup process, we have scanned this repository and found no existing alerts. In the future, you will see all code scanning alerts on the repository Security tab.

Copy link
Collaborator

@hmeneuvrier hmeneuvrier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Relecture OK, test OK pour la désactivation du bouton (c'est horrible de limiter le réseau), je ne sais pas comment simuler une erreur dans ce cas

@emilschn
Copy link
Collaborator Author

Relecture OK, test OK pour la désactivation du bouton (c'est horrible de limiter le réseau), je ne sais pas comment simuler une erreur dans ce cas

Pour simuler une erreur, tu écris moins de 10 caractères :)

{% endblock %}

{% block javascripts %}
{{ encore_entry_script_tags('app') }}
{% endblock %}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

manque un saut de ligne

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

t'es sûr pour les fichiers Twig ? Aucun de nos fichiers n'en a :)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dans ce cas on laisse comme ça

@hmeneuvrier
Copy link
Collaborator

Pour simuler une erreur, tu écris moins de 10 caractères :)

Alors c'est ok

{% endblock %}

{% block javascripts %}
{{ encore_entry_script_tags('app') }}
{% endblock %}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dans ce cas on laisse comme ça

@sfinx13 sfinx13 merged commit bd73239 into develop Apr 3, 2023
@emilschn emilschn deleted the fix/1074-disable-button-when-submit-form branch April 4, 2023 08:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants