Skip to content

Commit e3bf29c

Browse files
ahiuchingausmb2268
authored andcommitted
edit Hardware location items in ODD
1 parent 02f0bd7 commit e3bf29c

File tree

2 files changed

+16
-8
lines changed

2 files changed

+16
-8
lines changed

app/src/pages/ODD/ProtocolDetails/Hardware.tsx

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,10 @@ import {
1818
getFixtureDisplayName,
1919
getModuleDisplayName,
2020
getModuleType,
21+
getModuleDeckLabel,
2122
GRIPPER_V1_2,
2223
MAGNETIC_BLOCK_FIXTURES,
2324
MAGNETIC_BLOCK_TYPE,
24-
TC_MODULE_LOCATION_OT3,
25-
THERMOCYCLER_MODULE_TYPE,
2625
} from '@opentrons/shared-data'
2726

2827
import {
@@ -122,11 +121,13 @@ function HardwareItem({
122121
</LegacyStyledText>
123122
)
124123
if (hardware.hardwareType === 'module') {
125-
const slot =
126-
getModuleType(hardware.moduleModel) === THERMOCYCLER_MODULE_TYPE
127-
? TC_MODULE_LOCATION_OT3
128-
: hardware.slot
129-
location = <DeckInfoLabel deckLabel={slot} />
124+
location = (
125+
<DeckInfoLabel
126+
deckLabel={
127+
getModuleDeckLabel(getModuleType(hardware.moduleModel), hardware.slot)
128+
}
129+
/>
130+
)
130131
} else if (hardware.hardwareType === 'fixture') {
131132
location = (
132133
<DeckInfoLabel

app/src/pages/ODD/QuickTransferDetails/Hardware.tsx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ import {
1818
getFixtureDisplayName,
1919
getModuleDisplayName,
2020
getModuleType,
21+
getModuleDeckLabel,
2122
GRIPPER_V1_2,
2223
MAGNETIC_BLOCK_FIXTURES,
2324
MAGNETIC_BLOCK_TYPE,
@@ -120,7 +121,13 @@ function HardwareItem({
120121
</LegacyStyledText>
121122
)
122123
if (hardware.hardwareType === 'module') {
123-
location = <DeckInfoLabel deckLabel={hardware.slot} />
124+
location = (
125+
<DeckInfoLabel
126+
deckLabel={
127+
getModuleDeckLabel(getModuleType(hardware.moduleModel), hardware.slot)
128+
}
129+
/>
130+
)
124131
} else if (hardware.hardwareType === 'fixture') {
125132
location = (
126133
<DeckInfoLabel

0 commit comments

Comments
 (0)