added platform description to the firmware upgrade dialog
This commit is contained in:
parent
e535ec3c8b
commit
b3a50db873
2 changed files with 30 additions and 1 deletions
|
|
@ -270,7 +270,7 @@ export default function UpgradeDevice(props: Props) {
|
|||
<Divider />
|
||||
<DialogContent className={classes.dialogContent}>
|
||||
<DialogContentText id="alert-dialog-slide-description">
|
||||
Upgrading from {currentFirmware()} to {latestFirmware()}
|
||||
Upgrading {device.platformName()} from {currentFirmware()} to {latestFirmware()}
|
||||
<br />
|
||||
<br />
|
||||
It is recommended that the device be plugged in during the upgrade as it will take
|
||||
|
|
|
|||
|
|
@ -109,6 +109,35 @@ export class Device {
|
|||
return m;
|
||||
}
|
||||
|
||||
public platformName(): string {
|
||||
switch (this.settings.platform) {
|
||||
case pond.DevicePlatform.DEVICE_PLATFORM_PHOTON:
|
||||
return "Photon"
|
||||
case pond.DevicePlatform.DEVICE_PLATFORM_ELECTRON:
|
||||
return "Electron"
|
||||
case pond.DevicePlatform.DEVICE_PLATFORM_V2_CELLULAR:
|
||||
return "V2 Cellular"
|
||||
case pond.DevicePlatform.DEVICE_PLATFORM_V2_WIFI:
|
||||
return "V2 Wifi"
|
||||
case pond.DevicePlatform.DEVICE_PLATFORM_V2_WIFI_S3:
|
||||
return "V2 Wifi S3"
|
||||
case pond.DevicePlatform.DEVICE_PLATFORM_V2_CELLULAR_S3:
|
||||
return "V2 Cellular S3"
|
||||
case pond.DevicePlatform.DEVICE_PLATFORM_V2_CELLULAR_BLACK:
|
||||
return "V2 Cellular Black"
|
||||
case pond.DevicePlatform.DEVICE_PLATFORM_V2_CELLULAR_GREEN:
|
||||
return "V2 Callular Green"
|
||||
case pond.DevicePlatform.DEVICE_PLATFORM_V2_WIFI_BLUE:
|
||||
return "V2 Wifi Blue"
|
||||
case pond.DevicePlatform.DEVICE_PLATFORM_V2_CELLULAR_BLUE:
|
||||
return "V2 Cellular Blue"
|
||||
case pond.DevicePlatform.DEVICE_PLATFORM_V2_ETHERNET_BLUE:
|
||||
return "V2 Ethernet Blue"
|
||||
default:
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
public featureSupported(feature: string): boolean {
|
||||
let versions = featureVersions.get(feature);
|
||||
if (!versions) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue