mirror of
https://github.com/netbox-community/netbox.git
synced 2026-04-23 17:28:49 +02:00
implement 3664
This commit is contained in:
@@ -39,6 +39,8 @@ class ConfigContextQuerySet(QuerySet):
|
||||
else:
|
||||
regions = []
|
||||
|
||||
tags = obj.tags.slugs()
|
||||
|
||||
return self.filter(
|
||||
Q(regions__in=regions) | Q(regions=None),
|
||||
Q(sites=obj.site) | Q(sites=None),
|
||||
@@ -46,5 +48,6 @@ class ConfigContextQuerySet(QuerySet):
|
||||
Q(platforms=obj.platform) | Q(platforms=None),
|
||||
Q(tenant_groups=tenant_group) | Q(tenant_groups=None),
|
||||
Q(tenants=obj.tenant) | Q(tenants=None),
|
||||
Q(tags__name__in=tags) | Q(tags=None),
|
||||
is_active=True,
|
||||
).order_by('weight', 'name')
|
||||
|
||||
Reference in New Issue
Block a user