Skip to content

fix(leav/ui): record form create skip link/tree element errors before first submit - #992

Open
sberthier wants to merge 1 commit into
developfrom
fix/leav/ui/form-create-skip-link-tree-element-errors
Open

fix(leav/ui): record form create skip link/tree element errors before first submit#992
sberthier wants to merge 1 commit into
developfrom
fix/leav/ui/form-create-skip-link-tree-element-errors

Conversation

@sberthier

Copy link
Copy Markdown
Collaborator

Checklist

Definition Of Review

  • Own code review done (add notes for others)
  • Write message in teams channel
     <Title>
    
    *️⃣ Impacted projects : Core - DataStudio - Admin - @leav/ui - @leav/utils - ...
    
    📖 Ticket: https://aristid.atlassian.net/browse/<JIRA_TICKET_IDENTIFIER>
    
    🧑‍💻 PR: <link to PR/MR>
    
    ℹ Info: <brief explanation - context - how to test>
    

Definition Of Mergeable

  • 2 approves
  • 1 functional review - US has been tested
  • Every comment is handled - blocking ones have been resolved by reviewer
  • Design OK
  • Can be tested by POs
  • PR was introduced during daily meeting

@P0ppoff
P0ppoff requested a review from renaudAmsellem July 21, 2025 07:51
if (skipCheckElementErrors) {
// once submitted at least one time, show eventual fields errors
setSkipCheckElementErrors(false);
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

On met une rustine ici.
Pourquoi pas mais quelle est la raison de la soumission du formulaire au chargement de celui-ci ?

@sberthier sberthier Jul 21, 2025

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

J'ai pas de meilleur solution à mon niveau de connaissance des formulaire natif/antd/design-system/leav-ui. Peut-être y a t'il mieux à faire ?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Je regarde aujourd'hui.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

#1000

Qu'en penses tu ?

onFinish={() =>
onFinish={() => {
if (skipCheckElementErrors) {
// once submitted at least one time, show eventual fields errors

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Le commentaire explique ce que tu fais mais pas pourquoi.
Je te propose :

  • Aucun commentaire et l'intégrer dans le nommage (variable : avoidFormValidationOnLoad par ex) => Ma solution favorite : on se passe du commentaire.
  • 1 meilleur commentaire : "Creation form submits on load, we avoid the first validation with this skip"

@sberthier
sberthier force-pushed the fix/leav/ui/form-create-skip-link-tree-element-errors branch from 3f927c4 to 5e5ab8c Compare July 21, 2025 12:14
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.

4 participants