Skip to content

Object Hierarchy Constraints in NetBox Permissions #15426

Closed Locked Answered by candlerb
Kani999 asked this question in Help Wanted!
Discussion options

You must be logged in to vote

Can you clarify exactly what you're trying to do?

On dcim.Interface, it seems you are saying that constraint "device__tags__name" works but "device__tag__name" doesn't work. Isn't that expected? device has an attribute tags but not tag.

# /opt/netbox/venv/bin/python /opt/netbox/netbox/manage.py nbshell
...
>>> d=Device.objects.get(name="gw1")
>>> d.tags
<taggit.managers._TaggableManager object at 0x7f7263f34580>
>>> d.tag
Traceback (most recent call last):
  File "<console>", line 1, in <module>
AttributeError: 'Device' object has no attribute 'tag'

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@Kani999
Comment options

Answer selected by Kani999
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants