From: Stefan Hanreich <s.hanreich@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [PATCH pve-manager] ui: sdn: ipam: keep the subnets of different zones apart
Date: Thu, 19 Nov 2026 20:46:52 +0100 [thread overview]
Message-ID: <20261119194653.675296-1-s.hanreich@proxmox.com> (raw)
The IPAM tree grouped the entries by subnet alone. With the same subnet
in different zones, the entries of all these zones, including their
gateways, were shown in the subnet of the first zone.
Group the entries by zone and subnet, as the IPAM stores them.
Signed-off-by: Stefan Hanreich <s.hanreich@proxmox.com>
---
www/manager6/tree/DhcpTree.js | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/www/manager6/tree/DhcpTree.js b/www/manager6/tree/DhcpTree.js
index 40eb40bf..20f72d68 100644
--- a/www/manager6/tree/DhcpTree.js
+++ b/www/manager6/tree/DhcpTree.js
@@ -60,7 +60,9 @@ Ext.define('PVE.sdn.DhcpTree', {
zones[element.zone].children.push(vnet);
}
- if (!(element.subnet in subnets)) {
+ // subnets of different zones can overlap
+ let subnetKey = `${element.zone}/${element.subnet}`;
+ if (!(subnetKey in subnets)) {
let subnet = {
name: element.subnet,
zone: element.zone,
@@ -71,14 +73,14 @@ Ext.define('PVE.sdn.DhcpTree', {
children: [],
};
- subnets[element.subnet] = subnet;
+ subnets[subnetKey] = subnet;
vnets[element.vnet].children.push(subnet);
}
element.name = element.vmid; // for sorting
element.type = 'mapping';
element.iconCls = 'x-tree-icon-none';
- subnets[element.subnet].children.push(element);
+ subnets[subnetKey].children.push(element);
});
me.getView().setRootNode(root);
--
2.47.3
next reply other threads:[~2026-11-19 19:48 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-19 19:46 Stefan Hanreich [this message]
2026-11-19 23:16 ` applied: [PATCH pve-manager] ui: sdn: ipam: keep the subnets of different zones apart Thomas Lamprecht
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261119194653.675296-1-s.hanreich@proxmox.com \
--to=s.hanreich@proxmox.com \
--cc=pve-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.