Migrate Perlenkette using collapsed nodes#929
Draft
louisgreiner wants to merge 67 commits into
Draft
Conversation
5169a21 to
49d56d6
Compare
-first step to transform trainrunSection.nbOfStops, in actual nodes
Signed-off-by: Louis Greiner <greiner.louis@gmail.com>
Signed-off-by: Clara Ni <clara.ni@outlook.fr>
…unctions `TrainrunsectionHelper.getTravelTime()` computes the new travel time of a trainrunSection, either by using the `travelTimeFactor` and the current travel time of the section, or by using the total trainrun travel time and the sum of the new travel times computed up to that point. This logic can be split into 2 independent functions, which will be used depending on whether the considered section is the last one to compute or not. Signed-off-by: Clara Ni <clara.ni@outlook.fr>
…s service We used to destructure the times too early is the propagation process. Moving out the Math.max(.., Math.pow(..)) make getLastSectionTravelTime and getSectionDistributedTravelTime ensure we get a precise value of the travel time when calling these functions. Then, the minimum time is directly ensured by the TrainrunSectionTimesService. Signed-off-by: Louis Greiner <louis.greiner@proton.me>
Until now, a time structure has represented one or several trainrun sections without any stops, so it could be described by its departure and arrival times (right and left) and its travel time. Since we are now going to handle several trainrun sections that include stops, we need to add a new property to store the total stop time in the time structure. Signed-off-by: Clara Ni <clara.ni@outlook.fr>
…ode is masked The behavior is pretty much the same as when a node is a non-stop node, except when updating the travel time, because we need to take into account the stop times of the reduced nodes. Signed-off-by: Clara Ni <clara.ni@outlook.fr>
…he section tab Signed-off-by: Clara Ni <clara.ni@outlook.fr>
…vice Co-authored-by: Simon Ser <contact@emersion.fr>
TrainrunSectionViewObject will represent multiple trainrun sections soon. Add a helper to get the parent trainrun to reduce reliance on a single trainrun. Signed-off-by: Simon Ser <contact@emersion.fr>
…isSectionSelected() Preparation for the next commit. Signed-off-by: Simon Ser <contact@emersion.fr>
Collapsed nodes will make it so a single view object will need to display a chain of trainrun sections. For now, blindly replace trainrunSection with trainrunSections[0], to be cleaned up in future commits. Signed-off-by: Simon Ser <contact@emersion.fr>
…rateKey() We were only using the first trainrun section's path here. Expose a getPath() method to get a view object's path. We need to call it from inside generateKey() so drop the static attribute. While at it, make the generateKey() helper function private because it shouldn't be called from elsewhere. Signed-off-by: Simon Ser <contact@emersion.fr>
Supersedes TrainrunSection.path.textPositions because it takes into account collapsed nodes. Signed-off-by: Simon Ser <contact@emersion.fr>
…nodes Co-authored-by: Simon Ser <contact@emersion.fr>
Tests from trainrunsections.view.spec and data.view.spec.
This commit addresses issue: OpenRailAssociation/osrd#13292 Details: - Adds new component GlobalNodesManagementComponent in app/view/editor-edit-tools-view-component - The new component controls the isCollapsed state of the nodes - Adds EN and FR translations for the new component - Adds the new component to the existing EditorEditToolsViewComponent panel
Not used Signed-off-by: Clara Ni <clara.ni@outlook.fr>
The rest of the dto in the code will be dealt at the very end of the feature branch. Signed-off-by: Louis Greiner <louis.greiner@proton.me>
Signed-off-by: Louis Greiner <louis.greiner@proton.me>
…eTextPositions Signed-off-by: Louis Greiner <louis.greiner@proton.me>
….lastSection Signed-off-by: Louis Greiner <louis.greiner@proton.me>
We sent too many operations, especially during undockTransition, in an intermediate state that was not correct. Now we only send it at the end. Signed-off-by: Louis Greiner <louis.greiner@proton.me>
c1893cb to
9405e4f
Compare
49d56d6 to
6d0cce7
Compare
6d0cce7 to
d7e6696
Compare
bb4eef1 to
12bd9b0
Compare
12bd9b0 to
92ff856
Compare
92ff856 to
0db54d1
Compare
ebb3891 to
808b0f0
Compare
234859e to
edcd6d3
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements the "what you see is what you get" from the editor main view to the perlenkette
Closes #929