]> git.proxmox.com Git - pve-manager.git/commitdiff
ui: vm vNIC: make MTU validation more fine-grained for better UX
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Fri, 18 Nov 2022 10:44:43 +0000 (11:44 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Fri, 18 Nov 2022 10:44:47 +0000 (11:44 +0100)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
www/manager6/qemu/NetworkEdit.js

index 637449524755f25f7750c0d30cc4c5657e1f99df..d962d81a969b45a19e8fe3889546a47ec0e7f9e3 100644 (file)
@@ -117,6 +117,9 @@ Ext.define('PVE.qemu.NetworkInputPanel', {
                minValue: 1,
                maxValue: 65520,
                allowBlank: true,
+               validator: val => val === '' || val >= 576 || val === '1'
+                   ? true
+                   : gettext('MTU needs to be >= 576 or 1 to inherit the MTU from the underlying bridge.'),
            },
        ];