Ryan Merolle b0288037a2
Allow for ACL to VMs & Virtual Chassis on top of the current device association (#42)
* Associates hosts (devices, VMs, & virtual chassis) to each ACL
* Add a card to the object page for each of the above
* Update API & GraphQL
* Add a bulk delete button for ACL models
2022-07-21 10:30:52 -04:00

15 lines
385 B
Python

"""
Constants for filters
"""
from django.db.models import Q
ACL_HOST_ASSIGNMENT_MODELS = Q(
Q(app_label='dcim', model='device') |
Q(app_label='dcim', model='virtualchassis') |
Q(app_label='virtualization', model='virtualmachine')
)
ACL_INTERFACE_ASSIGNMENT_MODELS = Q(
Q(app_label='dcim', model='interface') |
Q(app_label='virtualization', model='vminterface')
)