mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-30 07:38:10 +00:00
train
This commit is contained in:
@@ -838,6 +838,12 @@ export default function BatchScheduleDetailPage() {
|
||||
}).format(new Date(data.scheduleDate)) + " EAT"
|
||||
: "No date"}
|
||||
</HeroChip>
|
||||
{data.train ? (
|
||||
<HeroChip icon={<TrainFront size={12} />}>
|
||||
Train {data.train.code}
|
||||
{data.train.trainName ? ` — ${data.train.trainName}` : ""}
|
||||
</HeroChip>
|
||||
) : null}
|
||||
{data.locomotive ? (
|
||||
<HeroChip icon={<TrainFront size={12} />}>
|
||||
Loco {data.locomotive.code} ·{" "}
|
||||
|
||||
@@ -757,13 +757,14 @@ export default function TrainScheduleV2DetailPage() {
|
||||
<Stack gap="md">
|
||||
<TrainCompositionDiagram
|
||||
locomotive={schedule.trainSet?.locomotive}
|
||||
locomotives={locomotives}
|
||||
wagons={
|
||||
schedule.trainSet?.wagons?.length
|
||||
? schedule.trainSet.wagons
|
||||
: displayWagonPlan
|
||||
}
|
||||
freightType={freightType}
|
||||
trainNumber={schedule.trainNumber}
|
||||
trainNumber={schedule.train ? schedule.train.code : schedule.trainNumber}
|
||||
totalLengthMeters={schedule.trainSet?.totalLengthMeters}
|
||||
/>
|
||||
<Paper
|
||||
@@ -1003,6 +1004,16 @@ export default function TrainScheduleV2DetailPage() {
|
||||
|
||||
<KpiStrip
|
||||
items={[
|
||||
...(schedule.train
|
||||
? [
|
||||
{
|
||||
label: "Train",
|
||||
value: schedule.train.code,
|
||||
hint: schedule.train.trainName ?? "Built train (Train Builder)",
|
||||
icon: Train,
|
||||
},
|
||||
]
|
||||
: []),
|
||||
{
|
||||
label: locomotives.length > 1 ? "Locomotives" : "Locomotive",
|
||||
value: locomotives.length
|
||||
|
||||
Reference in New Issue
Block a user