Compare commits
2 Commits
f55915073f
...
6dc07900eb
Author | SHA1 | Date |
---|---|---|
Noe | 6dc07900eb | |
Noe | 42ba224603 |
|
@ -375,6 +375,112 @@ function BatteryView(props: BatteryViewProps) {
|
|||
</TableCell>
|
||||
</>
|
||||
)}
|
||||
|
||||
{props.productNum === 1 && (
|
||||
<>
|
||||
<TableCell
|
||||
style={{
|
||||
width: '20%',
|
||||
textAlign: 'center',
|
||||
padding: '8px',
|
||||
fontWeight:
|
||||
Number(battery.Warnings.value) !== 0
|
||||
? 'bold'
|
||||
: 'inherit',
|
||||
backgroundColor:
|
||||
Number(battery.Warnings.value) === 0
|
||||
? 'inherit'
|
||||
: '#ff9900',
|
||||
color:
|
||||
Number(battery.Warnings.value) != 0
|
||||
? 'black'
|
||||
: 'inherit'
|
||||
}}
|
||||
>
|
||||
{Number(battery.Warnings.value) === 0 ? (
|
||||
'None'
|
||||
) : Number(battery.Warnings.value) === 1 ? (
|
||||
<Link
|
||||
style={{ color: 'black' }}
|
||||
to={
|
||||
currentLocation.pathname.substring(
|
||||
0,
|
||||
currentLocation.pathname.lastIndexOf('/') + 1
|
||||
) +
|
||||
routes.log +
|
||||
'?open=warning'
|
||||
}
|
||||
>
|
||||
New Warning
|
||||
</Link>
|
||||
) : (
|
||||
<Link
|
||||
style={{ color: 'black' }}
|
||||
to={
|
||||
currentLocation.pathname.substring(
|
||||
0,
|
||||
currentLocation.pathname.lastIndexOf('/') + 1
|
||||
) +
|
||||
routes.log +
|
||||
'?open=warning'
|
||||
}
|
||||
>
|
||||
Multiple Warnings
|
||||
</Link>
|
||||
)}
|
||||
</TableCell>
|
||||
<TableCell
|
||||
sx={{
|
||||
width: '20%',
|
||||
textAlign: 'center',
|
||||
fontWeight:
|
||||
Number(battery.Alarms.value) !== 0
|
||||
? 'bold'
|
||||
: 'inherit',
|
||||
backgroundColor:
|
||||
Number(battery.Alarms.value) === 0
|
||||
? 'inherit'
|
||||
: '#FF033E',
|
||||
color:
|
||||
Number(battery.Alarms.value) != 0
|
||||
? 'black'
|
||||
: 'inherit'
|
||||
}}
|
||||
>
|
||||
{Number(battery.Alarms.value) === 0 ? (
|
||||
'None'
|
||||
) : Number(battery.Alarms.value) === 1 ? (
|
||||
<Link
|
||||
style={{ color: 'black' }}
|
||||
to={
|
||||
currentLocation.pathname.substring(
|
||||
0,
|
||||
currentLocation.pathname.lastIndexOf('/') + 1
|
||||
) +
|
||||
routes.log +
|
||||
'?open=error'
|
||||
}
|
||||
>
|
||||
New Alarm
|
||||
</Link>
|
||||
) : (
|
||||
<Link
|
||||
style={{ color: 'black' }}
|
||||
to={
|
||||
currentLocation.pathname.substring(
|
||||
0,
|
||||
currentLocation.pathname.lastIndexOf('/') + 1
|
||||
) +
|
||||
routes.log +
|
||||
'?open=error'
|
||||
}
|
||||
>
|
||||
Multiple Alarms
|
||||
</Link>
|
||||
)}
|
||||
</TableCell>
|
||||
</>
|
||||
)}
|
||||
</TableRow>
|
||||
))}
|
||||
</TableBody>
|
||||
|
|
|
@ -335,7 +335,7 @@ function DetailedBatteryView(props: DetailedBatteryViewProps) {
|
|||
...batteryStringStyle,
|
||||
backgroundColor:
|
||||
props.batteryData.String1Active.value == 'True' ||
|
||||
props.batteryData.String4Active.value == 0
|
||||
Number(props.batteryData.String1Active.value) == 0
|
||||
? '#32CD32'
|
||||
: '#FF033E'
|
||||
}}
|
||||
|
@ -345,7 +345,7 @@ function DetailedBatteryView(props: DetailedBatteryViewProps) {
|
|||
...batteryStringStyle,
|
||||
backgroundColor:
|
||||
props.batteryData.String2Active.value == 'True' ||
|
||||
props.batteryData.String4Active.value == 0
|
||||
Number(props.batteryData.String2Active.value) == 0
|
||||
? '#32CD32'
|
||||
: '#FF033E'
|
||||
}}
|
||||
|
@ -355,7 +355,7 @@ function DetailedBatteryView(props: DetailedBatteryViewProps) {
|
|||
...batteryStringStyle,
|
||||
backgroundColor:
|
||||
props.batteryData.String3Active.value == 'True' ||
|
||||
props.batteryData.String4Active.value == 0
|
||||
Number(props.batteryData.String3Active.value) == 0
|
||||
? '#32CD32'
|
||||
: '#FF033E'
|
||||
}}
|
||||
|
@ -365,7 +365,7 @@ function DetailedBatteryView(props: DetailedBatteryViewProps) {
|
|||
...batteryStringStyle,
|
||||
backgroundColor:
|
||||
props.batteryData.String4Active.value == 'True' ||
|
||||
props.batteryData.String4Active.value == 0
|
||||
Number(props.batteryData.String4Active.value) == 0
|
||||
? '#32CD32'
|
||||
: '#FF033E'
|
||||
}}
|
||||
|
@ -375,7 +375,7 @@ function DetailedBatteryView(props: DetailedBatteryViewProps) {
|
|||
...batteryStringStyle,
|
||||
backgroundColor:
|
||||
props.batteryData.String5Active.value == 'True' ||
|
||||
props.batteryData.String4Active.value == 0
|
||||
Number(props.batteryData.String5Active.value) == 0
|
||||
? '#32CD32'
|
||||
: '#FF033E'
|
||||
}}
|
||||
|
@ -639,6 +639,7 @@ function DetailedBatteryView(props: DetailedBatteryViewProps) {
|
|||
</Card>
|
||||
</Grid>
|
||||
{/*----------------------------------------------------------------------------------------------------------------------------------*/}
|
||||
|
||||
{props.productNum === 0 && (
|
||||
<>
|
||||
<Grid item md={3} xs={3}>
|
||||
|
|
|
@ -275,6 +275,19 @@ function InformationSalidomo(props: InformationSalidomoProps) {
|
|||
/>
|
||||
</div>
|
||||
|
||||
{/*<div>*/}
|
||||
{/* <TextField*/}
|
||||
{/* label={*/}
|
||||
{/* <FormattedMessage id="vrmLink" defaultMessage="vrmLink" />*/}
|
||||
{/* }*/}
|
||||
{/* name="vrmLink"*/}
|
||||
{/* value={formValues.vrmLink}*/}
|
||||
{/* onChange={handleChange}*/}
|
||||
{/* variant="outlined"*/}
|
||||
{/* fullWidth*/}
|
||||
{/* />*/}
|
||||
{/*</div>*/}
|
||||
|
||||
<div>
|
||||
<TextField
|
||||
label="S3 Bucket Name"
|
||||
|
|
Loading…
Reference in New Issue