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

fix(launcher): adds default time limit submission #1976

Merged
merged 6 commits into from
Mar 14, 2024

Conversation

hdinia
Copy link
Member

@hdinia hdinia commented Mar 11, 2024

Related to: https://gopro-tickets.rte-france.com/browse/ANT-1271

Description:

This pull request fixes an issue in the LauncherDialog component where the time_limit state was not correctly set to a default value if the user modified fields other than the time limit itself before launching a simulation.
Despite the UI correctly displaying the default time limit (converted from seconds to hours for user readability), the internal state time_limit remained unset if the user did not explicitly change the time limit field.
This could lead to unintended behavior when submitting the form.

Key Changes:

Initialization of time_limit State:
Ensured the time_limit state is initialized with DEFAULT_TIME_LIMIT in the component's initial state. This guarantees that the state correctly reflects the displayed default time limit even if the user does not interact with the time limit field.

@hdinia hdinia force-pushed the bugfix/default-time-limit-submission branch 6 times, most recently from 89d9cee to cdebd07 Compare March 13, 2024 14:59
@laurent-laporte-pro laurent-laporte-pro force-pushed the bugfix/default-time-limit-submission branch from cdebd07 to 60cca11 Compare March 14, 2024 11:07
@laurent-laporte-pro laurent-laporte-pro merged commit 8b00715 into dev Mar 14, 2024
7 checks passed
@laurent-laporte-pro laurent-laporte-pro deleted the bugfix/default-time-limit-submission branch March 14, 2024 12:37
@makdeuneuv makdeuneuv added this to the v2.17.1 milestone May 13, 2024
@laurent-laporte-pro laurent-laporte-pro modified the milestones: v2.17.1, v2.17 May 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants