-
Notifications
You must be signed in to change notification settings - Fork 45
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 displayed op on manchette #10334
base: dev
Are you sure you want to change the base?
Changes from all commits
d1cebae
3061e14
15b3be9
6ce3e95
4b5218a
456612e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not sure where it comes from, but there is a white screen if we try to switch to linear mode in the manchette |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,7 +13,6 @@ import { | |
type TrainScheduleResult, | ||
} from 'common/api/osrdEditoastApi'; | ||
import { useOsrdConfSelectors } from 'common/osrdContext'; | ||
import { isStation } from 'modules/pathfinding/utils'; | ||
|
||
const useGetProjectedTrainOperationalPoints = ( | ||
trainScheduleUsedForProjection?: TrainScheduleResult, | ||
|
@@ -76,14 +75,8 @@ const useGetProjectedTrainOperationalPoints = ( | |
operationalPointsWithUniqueIds = JSON.parse(stringifiedSavedWaypoints) as NonNullable< | ||
PathProperties['operational_points'] | ||
>; | ||
} else { | ||
// If the manchette hasn't been saved, we want to display by default only | ||
// the waypoints with CH BV/00/'' and the ones added by map click | ||
operationalPointsWithUniqueIds = operationalPointsWithUniqueIds.filter((op) => | ||
op.extensions?.sncf ? isStation(op.extensions.sncf.ch) : true | ||
); | ||
} | ||
setFilteredOperationalPoints(operationalPointsWithUniqueIds); | ||
setFilteredOperationalPoints(operationalPointsWithAllWaypoints); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think we should change this. Otherwise, we won't have any waypoint checked in the waypoint panel. |
||
} | ||
}; | ||
getOperationalPoints(); | ||
|
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.
Should be outside of the function
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.
fixed