Skip to content

Ajout d‘une vérification si un champ existe dans dsfr_input_class_attr()#234

Merged
Ash-Crow merged 3 commits intomainfrom
form-field-error
Jun 3, 2025
Merged

Ajout d‘une vérification si un champ existe dans dsfr_input_class_attr()#234
Ash-Crow merged 3 commits intomainfrom
form-field-error

Conversation

@Ash-Crow
Copy link
Collaborator

@Ash-Crow Ash-Crow commented Jun 2, 2025

🎯 Objectif

Fix #232

Permet un meilleur message d’erreur quand un champ inexistant est appelé. Malheureusement, le nom du champ est inaccessible à ce stade, s'il n’existe pas c'est une chaîne vide qui est passée au lieu d’un BoundField : impossible de donner le nom du champ en erreur dans le message d’erreur

🔍 Implémentation

  • Ajout d’une vérification à la méthode dsfr_input_class_attr()

🏕 Amélioration continue

  • Ajout de tests basiques sur les formulaires.

@Ash-Crow Ash-Crow requested a review from Luzzzi June 2, 2025 15:19
@Ash-Crow Ash-Crow force-pushed the form-field-error branch from 50ba052 to 50b3239 Compare June 3, 2025 09:49
@Ash-Crow Ash-Crow merged commit 5956d50 into main Jun 3, 2025
7 checks passed
@David-Guillot David-Guillot deleted the form-field-error branch February 13, 2026 09:40
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.

Erreur cryptique avec le tag {% dsfr_form_field form.FOO %}

2 participants