]> git.proxmox.com Git - pve-manager.git/commitdiff
ui: size-field: add more units
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Wed, 21 Apr 2021 11:11:39 +0000 (13:11 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Wed, 21 Apr 2021 11:11:41 +0000 (13:11 +0200)
This would probably benefit from being an object alá:
```
'GiB': {
    base: 2,
    order: 30,
},
```
but that would be a transparent internal change, and the current way
isn't yet a limitation, so ...

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
www/manager6/form/BandwidthSelector.js

index 84c5ab35171173d0da6577c24d0885ffb2f97201..651b175aa16cabf8732358e3972e02f0c6086bba 100644 (file)
@@ -22,12 +22,15 @@ Ext.define('PVE.form.SizeField', {
     },
 
     units: {
+       'B': 1,
        'KiB': 1024,
        'MiB': 1024*1024,
        'GiB': 1024*1024*1024,
+       'TiB': 1024*1024*1024*1024,
        'KB': 1000,
        'MB': 1000*1000,
        'GB': 1000*1000*1000,
+       'TB': 1000*1000*1000*1000,
     },
 
     // display unit (TODO: make (optionally) selectable)