mirror of
https://git.proxmox.com/git/pve-manager
synced 2025-08-03 05:16:26 +00:00
ext6migrate: change status units to binary prefixes
we used a factor of 2^10 when calculating, but wrote MB,GB,etc which is not (entirely) correct this patch changes the units to MiB, GiB, etc, because this is more sensible than changing the calculation Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
parent
b549494539
commit
7b9c038d54
@ -624,24 +624,24 @@ Ext.define('PVE.Utils', { statics: {
|
||||
var kb = size / 1024;
|
||||
|
||||
if (kb < 1024) {
|
||||
return kb.toFixed(0) + "KB";
|
||||
return kb.toFixed(0) + "KiB";
|
||||
}
|
||||
|
||||
var mb = size / (1024*1024);
|
||||
|
||||
if (mb < 1024) {
|
||||
return mb.toFixed(0) + "MB";
|
||||
return mb.toFixed(0) + "MiB";
|
||||
}
|
||||
|
||||
var gb = mb / 1024;
|
||||
|
||||
if (gb < 1024) {
|
||||
return gb.toFixed(2) + "GB";
|
||||
return gb.toFixed(2) + "GiB";
|
||||
}
|
||||
|
||||
var tb = gb / 1024;
|
||||
|
||||
return tb.toFixed(2) + "TB";
|
||||
return tb.toFixed(2) + "TiB";
|
||||
|
||||
},
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user