Просмотр исходного кода

Fixes #2841: Fix filtering by VRF for prefix and IP address lists

Jeremy Stretch 7 лет назад
Родитель
Сommit
42d1d6e1b0
2 измененных файлов с 3 добавлено и 2 удалено
  1. 1 0
      CHANGELOG.md
  2. 2 2
      netbox/ipam/forms.py

+ 1 - 0
CHANGELOG.md

@@ -2,6 +2,7 @@ v2.5.6 (FUTURE)
 
 
 ## Bug Fixes
 ## Bug Fixes
 
 
+* [#2841](https://github.com/digitalocean/netbox/issues/2841) - Fix filtering by VRF for prefix and IP address lists
 * [#2844](https://github.com/digitalocean/netbox/issues/2844) - Correct display of far cable end for pass-through ports
 * [#2844](https://github.com/digitalocean/netbox/issues/2844) - Correct display of far cable end for pass-through ports
 * [#2845](https://github.com/digitalocean/netbox/issues/2845) - Enable filtering of rack unit list by unit ID
 * [#2845](https://github.com/digitalocean/netbox/issues/2845) - Enable filtering of rack unit list by unit ID
 * [#2856](https://github.com/digitalocean/netbox/issues/2856) - Fix navigation links between LAG interfaces and their members on device view
 * [#2856](https://github.com/digitalocean/netbox/issues/2856) - Fix navigation links between LAG interfaces and their members on device view

+ 2 - 2
netbox/ipam/forms.py

@@ -531,7 +531,7 @@ class PrefixFilterForm(BootstrapMixin, CustomFieldFilterForm):
         null_label='-- Global --',
         null_label='-- Global --',
         widget=APISelectMultiple(
         widget=APISelectMultiple(
             api_url="/api/ipam/vrfs/",
             api_url="/api/ipam/vrfs/",
-            value_field="slug",
+            value_field="rd",
             null_option=True,
             null_option=True,
         )
         )
     )
     )
@@ -980,7 +980,7 @@ class IPAddressFilterForm(BootstrapMixin, CustomFieldFilterForm):
         null_label='-- Global --',
         null_label='-- Global --',
         widget=APISelectMultiple(
         widget=APISelectMultiple(
             api_url="/api/ipam/vrfs/",
             api_url="/api/ipam/vrfs/",
-            value_field="slug",
+            value_field="rd",
             null_option=True,
             null_option=True,
         )
         )
     )
     )