Skip to content

Commit 2571845

Browse files
committed
refactor(graphql): Use NetBoxObjectType
Refactors AccessListType and related classes to use NetBoxObjectType. This improves consistency by aligning with the updated base type in the codebase. No functional changes introduced. Fixes: #249
1 parent 5deb1b4 commit 2571845

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

netbox_acls/graphql/types.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
import strawberry
88
import strawberry_django
9-
from netbox.graphql.types import OrganizationalObjectType
9+
from netbox.graphql.types import NetBoxObjectType
1010

1111
from .. import models
1212
from . import filters
@@ -18,7 +18,7 @@
1818
exclude=["assigned_object_type", "assigned_object_id"],
1919
filters=filters.AccessListFilter,
2020
)
21-
class AccessListType(OrganizationalObjectType):
21+
class AccessListType(NetBoxObjectType):
2222
"""
2323
Defines the object type for the django model AccessList.
2424
"""
@@ -48,7 +48,7 @@ def accesslists(self) -> List[Annotated["AccessList", strawberry.lazy("accesslis
4848
exclude=["assigned_object_type", "assigned_object_id"],
4949
filters=filters.ACLInterfaceAssignmentFilter,
5050
)
51-
class ACLInterfaceAssignmentType(OrganizationalObjectType):
51+
class ACLInterfaceAssignmentType(NetBoxObjectType):
5252
"""
5353
Defines the object type for the django model AccessList.
5454
"""
@@ -80,7 +80,7 @@ def aclinterfaceassignments(
8080
fields="__all__",
8181
filters=filters.ACLExtendedRuleFilter,
8282
)
83-
class ACLExtendedRuleType(OrganizationalObjectType):
83+
class ACLExtendedRuleType(NetBoxObjectType):
8484
"""
8585
Defines the object type for the django model ACLExtendedRule.
8686
"""
@@ -108,7 +108,7 @@ def aclextendedrules(
108108
fields="__all__",
109109
filters=filters.ACLStandardRuleFilter,
110110
)
111-
class ACLStandardRuleType(OrganizationalObjectType):
111+
class ACLStandardRuleType(NetBoxObjectType):
112112
"""
113113
Defines the object type for the django model ACLStandardRule.
114114
"""

0 commit comments

Comments
 (0)