@@ -10,6 +10,7 @@ import allowancesPic from 'assets/pictures/components/allowances.svg';
10
10
import pahtFindingPic from 'assets/pictures/components/pathfinding.svg' ;
11
11
import simulationSettings from 'assets/pictures/components/simulationSettings.svg' ;
12
12
import rollingStockPic from 'assets/pictures/components/train.svg' ;
13
+ import type { Distribution } from 'common/api/osrdEditoastApi' ;
13
14
import { useOsrdConfSelectors } from 'common/osrdContext' ;
14
15
import { useStoreDataForSpeedLimitByTagSelector } from 'common/SpeedLimitByTagSelector/useStoreDataForSpeedLimitByTagSelector' ;
15
16
import Tabs from 'common/Tabs' ;
@@ -30,18 +31,19 @@ import { formatKmValue } from 'utils/strings';
30
31
31
32
type ManageTrainScheduleProps = {
32
33
trainIdToEdit ?: number ;
34
+ constraintDistribution : Distribution ;
33
35
} ;
34
36
35
- const ManageTrainSchedule = ( { trainIdToEdit } : ManageTrainScheduleProps ) => {
37
+ const ManageTrainSchedule = ( {
38
+ trainIdToEdit,
39
+ constraintDistribution,
40
+ } : ManageTrainScheduleProps ) => {
36
41
const { t } = useTranslation ( [ 'operationalStudies/manageTrainSchedule' ] ) ;
37
- const { getOrigin, getDestination, getPathSteps, getConstraintDistribution, getStartTime } =
38
- useOsrdConfSelectors ( ) ;
42
+ const { getOrigin, getDestination, getPathSteps, getStartTime } = useOsrdConfSelectors ( ) ;
39
43
const origin = useSelector ( getOrigin ) ;
40
44
const destination = useSelector ( getDestination ) ;
41
45
const pathSteps = useSelector ( getPathSteps ) ;
42
- const constraintDistribution = useSelector ( getConstraintDistribution ) ;
43
46
const startTime = useSelector ( getStartTime ) ;
44
-
45
47
const [ pathProperties , setPathProperties ] = useState < ManageTrainSchedulePathProperties > ( ) ;
46
48
47
49
const { speedLimitByTag, speedLimitsByTags, dispatchUpdateSpeedLimitByTag } =
0 commit comments