mirror of
https://github.com/netbox-community/netbox.git
synced 2026-01-25 04:50:00 -06:00
Introduce the wireless app and SSID model
This commit is contained in:
0
netbox/wireless/graphql/__init__.py
Normal file
0
netbox/wireless/graphql/__init__.py
Normal file
9
netbox/wireless/graphql/schema.py
Normal file
9
netbox/wireless/graphql/schema.py
Normal file
@@ -0,0 +1,9 @@
|
||||
import graphene
|
||||
|
||||
from netbox.graphql.fields import ObjectField, ObjectListField
|
||||
from .types import *
|
||||
|
||||
|
||||
class WirelessQuery(graphene.ObjectType):
|
||||
ssid = ObjectField(SSIDType)
|
||||
ssid_list = ObjectListField(SSIDType)
|
||||
14
netbox/wireless/graphql/types.py
Normal file
14
netbox/wireless/graphql/types.py
Normal file
@@ -0,0 +1,14 @@
|
||||
from wireless import filtersets, models
|
||||
from netbox.graphql.types import ObjectType
|
||||
|
||||
__all__ = (
|
||||
'SSIDType',
|
||||
)
|
||||
|
||||
|
||||
class SSIDType(ObjectType):
|
||||
|
||||
class Meta:
|
||||
model = models.SSID
|
||||
fields = '__all__'
|
||||
filterset_class = filtersets.SSIDFilterSet
|
||||
Reference in New Issue
Block a user