mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-07 00:09:51 +03:00
merge changes from Michael for #600
This commit is contained in:
@@ -199,10 +199,12 @@ const SettingsEntities: FC = () => {
|
||||
setDialogOpen(true);
|
||||
};
|
||||
|
||||
function formatValue(value: any, uom: any) {
|
||||
function formatValue(value: any, uom: number) {
|
||||
return value === undefined || uom === undefined
|
||||
? ''
|
||||
: new Intl.NumberFormat().format(value) + (uom === 0 ? '' : ' ' + DeviceValueUOM_s[uom]);
|
||||
: typeof value === 'number'
|
||||
? new Intl.NumberFormat().format(value) + (uom === 0 ? '' : ' ' + DeviceValueUOM_s[uom])
|
||||
: value;
|
||||
}
|
||||
|
||||
function showHex(value: number, digit: number) {
|
||||
|
||||
Reference in New Issue
Block a user