Upstream proxmox-git/pve-manager state of the touched files before 338e084bf0
This commit is contained in:
1 parent
5537758fe8
commit
9584686a33
2 files changed
+1630
No files matched your search
+1620
File diff suppressed because it is too large.
Load diff
@@ -1207,6 +1207,16 @@ Ext.define('PVE.Utils', {
|
|||||||
if (!Ext.isNumeric(value) || value === -1) {
|
if (!Ext.isNumeric(value) || value === -1) {
|
||||||
return '';
|
return '';
|
||||||
}
|
}
|
||||||
|
if (value > 1) {
|
||||||
|
// we got no percentage but bytes
|
||||||
|
let mem = value;
|
||||||
|
let maxmem = record.data.maxmem;
|
||||||
|
if (!record.data.uptime || maxmem === 0 || !Ext.isNumeric(mem)) {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
|
|
||||||
|
return ((mem * 100) / maxmem).toFixed(1) + ' %';
|
||||||
|
}
|
||||||
return (value * 100).toFixed(1) + ' %';
|
return (value * 100).toFixed(1) + ' %';
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user