-
Notifications
You must be signed in to change notification settings - Fork 46
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
front: fix train edition setup #9826
Conversation
Codecov ReportAttention: Patch coverage is
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## dev #9826 +/- ##
==========================================
+ Coverage 37.82% 37.85% +0.03%
==========================================
Files 994 994
Lines 91126 91167 +41
Branches 1176 1191 +15
==========================================
+ Hits 34468 34514 +46
+ Misses 56204 56199 -5
Partials 454 454
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
66abf82
to
95f3780
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm (tested)
Since recently, when opening the view to edit a train, a pathfinding request is automatically launched. But it is launched before the store update, which creates the bug: the pathfinding is launched with the pathsteps stored in the store (and not the ones of the train we want to edit) and once the pathfinding request is finished, we update the store with the result of the request (and erase the path steps of the currently selected train). To fix this, we can directly update the store before opening the ManageTrainSchedule view. Signed-off-by: Clara Ni <[email protected]>
95f3780
to
e18a810
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM !
closes #9805
Since recently, when opening the view to edit a train, a pathfinding request is automatically launched. But it is launched before the store update, which creates the bug: the pathfinding is launched with the pathsteps stored in the store (and not the ones of the train we want to edit) and once the pathfinding request is finished, we update the store with the result of the request (and erase the path steps of the currently selected train).
To fix this, we can directly update the store before opening the ManageTrainSchedule view.