[PR #19161] [CLOSED] Fixes #18879 - Add prefix filtering by assigned VLAN group #15547

Closed
opened 2025-12-30 00:22:36 +01:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/netbox-community/netbox/pull/19161
Author: @pheus
Created: 4/13/2025
Status: Closed

Base: mainHead: feature/18879-add-prefix-filtering-by-vlan-group


📝 Commits (3)

  • 5aa302d feat(ipam): Add VLAN group filters to IPAM FilterSet
  • 2ec0676 feat(ipam): Add VLAN group filter in IPAM FilterForm
  • bbb52b4 feat(ipam): Add VLAN group filtering to tests

📊 Changes

3 files changed (+36 additions, -3 deletions)

View changed files

📝 netbox/ipam/filtersets.py (+12 -0)
📝 netbox/ipam/forms/filtersets.py (+6 -1)
📝 netbox/ipam/tests/test_filtersets.py (+18 -2)

📄 Description

Fixes #18879 - Add prefix filtering by assigned VLAN Group

Overview

This PR enhances NetBox by enabling filtering of prefixes by the assigned VLAN Group. Users can now filter using both quick search (by VLAN Group slug) and FilterForm (by ID).

Changes Introduced

  • IPAM FilterSet: Added VLAN Group filters to support filtering by both ID and slug.
  • IPAM FilterForm: Introduced a vlan_group_id filter for direct filtering by VLAN Group.
  • Testing: Added tests to validate VLAN Group filtering.

Thank you for reviewing this PR!


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/netbox-community/netbox/pull/19161 **Author:** [@pheus](https://github.com/pheus) **Created:** 4/13/2025 **Status:** ❌ Closed **Base:** `main` ← **Head:** `feature/18879-add-prefix-filtering-by-vlan-group` --- ### 📝 Commits (3) - [`5aa302d`](https://github.com/netbox-community/netbox/commit/5aa302d351f7efc1cf8ae1515fa45cbb4ecee173) feat(ipam): Add VLAN group filters to IPAM FilterSet - [`2ec0676`](https://github.com/netbox-community/netbox/commit/2ec06769425f0eb0de9569b258dd87f783d45dfd) feat(ipam): Add VLAN group filter in IPAM FilterForm - [`bbb52b4`](https://github.com/netbox-community/netbox/commit/bbb52b4c4e6b9afb88a0fc2ab007f7ffcbcec3bb) feat(ipam): Add VLAN group filtering to tests ### 📊 Changes **3 files changed** (+36 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `netbox/ipam/filtersets.py` (+12 -0) 📝 `netbox/ipam/forms/filtersets.py` (+6 -1) 📝 `netbox/ipam/tests/test_filtersets.py` (+18 -2) </details> ### 📄 Description <!-- Thank you for your interest in contributing to NetBox! Please note that our contribution policy requires that a feature request or bug report be approved and assigned prior to opening a pull request. This helps avoid waste time and effort on a proposed change that we might not be able to accept. IF YOUR PULL REQUEST DOES NOT REFERENCE AN ISSUE WHICH HAS BEEN ASSIGNED TO YOU, IT WILL BE CLOSED AUTOMATICALLY. Please specify your assigned issue number on the line below. --> ### Fixes #18879 - Add prefix filtering by assigned VLAN Group #### Overview This PR enhances NetBox by enabling filtering of prefixes by the assigned VLAN Group. Users can now filter using both quick search (by VLAN Group slug) and FilterForm (by ID). #### Changes Introduced - **IPAM FilterSet:** Added VLAN Group filters to support filtering by both ID and slug. - **IPAM FilterForm:** Introduced a `vlan_group_id` filter for direct filtering by VLAN Group. - **Testing:** Added tests to validate VLAN Group filtering. Thank you for reviewing this PR! --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2025-12-30 00:22:36 +01:00
adam closed this issue 2025-12-30 00:22:37 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#15547