1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Correct serializer field lists

This commit is contained in:
Jeremy Stretch
2020-10-06 15:27:40 -04:00
parent 3870f5d246
commit 52ec35b94f
2 changed files with 11 additions and 8 deletions

View File

@ -78,4 +78,5 @@ class CircuitTerminationSerializer(CableTerminationSerializer, ConnectedEndpoint
fields = [
'id', 'url', 'circuit', 'term_side', 'site', 'port_speed', 'upstream_speed', 'xconnect_id', 'pp_info',
'description', 'connected_endpoint_type', 'connected_endpoint', 'connected_endpoint_reachable', 'cable',
'cable_peer', 'cable_peer_type',
]

View File

@ -487,7 +487,7 @@ class ConsoleServerPortSerializer(TaggedObjectSerializer, CableTerminationSerial
model = ConsoleServerPort
fields = [
'id', 'url', 'device', 'name', 'label', 'type', 'description', 'connected_endpoint_type',
'connected_endpoint', 'connected_endpoint_reachable', 'cable', 'cable_peer', 'tags',
'connected_endpoint', 'connected_endpoint_reachable', 'cable', 'cable_peer', 'cable_peer_type', 'tags',
]
@ -505,7 +505,7 @@ class ConsolePortSerializer(TaggedObjectSerializer, CableTerminationSerializer,
model = ConsolePort
fields = [
'id', 'url', 'device', 'name', 'label', 'type', 'description', 'connected_endpoint_type',
'connected_endpoint', 'connected_endpoint_reachable', 'cable', 'cable_peer', 'tags',
'connected_endpoint', 'connected_endpoint_reachable', 'cable', 'cable_peer', 'cable_peer_type', 'tags',
]
@ -534,7 +534,7 @@ class PowerOutletSerializer(TaggedObjectSerializer, CableTerminationSerializer,
fields = [
'id', 'url', 'device', 'name', 'label', 'type', 'power_port', 'feed_leg', 'description',
'connected_endpoint_type', 'connected_endpoint', 'connected_endpoint_reachable', 'cable', 'cable_peer',
'tags',
'cable_peer_type', 'tags',
]
@ -553,7 +553,7 @@ class PowerPortSerializer(TaggedObjectSerializer, CableTerminationSerializer, Co
fields = [
'id', 'url', 'device', 'name', 'label', 'type', 'maximum_draw', 'allocated_draw', 'description',
'connected_endpoint_type', 'connected_endpoint', 'connected_endpoint_reachable', 'cable', 'cable_peer',
'tags',
'cable_peer_type', 'tags',
]
@ -578,7 +578,7 @@ class InterfaceSerializer(TaggedObjectSerializer, CableTerminationSerializer, Co
fields = [
'id', 'url', 'device', 'name', 'label', 'type', 'enabled', 'lag', 'mtu', 'mac_address', 'mgmt_only',
'description', 'connected_endpoint_type', 'connected_endpoint', 'connected_endpoint_reachable', 'cable',
'cable_peer', 'mode', 'untagged_vlan', 'tagged_vlans', 'tags', 'count_ipaddresses',
'cable_peer', 'cable_peer_type', 'mode', 'untagged_vlan', 'tagged_vlans', 'tags', 'count_ipaddresses',
]
# TODO: This validation should be handled by Interface.clean()
@ -611,7 +611,8 @@ class RearPortSerializer(TaggedObjectSerializer, CableTerminationSerializer, Val
class Meta:
model = RearPort
fields = [
'id', 'url', 'device', 'name', 'label', 'type', 'positions', 'description', 'cable', 'cable_peer', 'tags',
'id', 'url', 'device', 'name', 'label', 'type', 'positions', 'description', 'cable', 'cable_peer',
'cable_peer_type', 'tags',
]
@ -637,7 +638,7 @@ class FrontPortSerializer(TaggedObjectSerializer, CableTerminationSerializer, Va
model = FrontPort
fields = [
'id', 'url', 'device', 'name', 'label', 'type', 'rear_port', 'rear_port_position', 'description', 'cable',
'cable_peer', 'tags',
'cable_peer', 'cable_peer_type', 'tags',
]
@ -821,5 +822,6 @@ class PowerFeedSerializer(
fields = [
'id', 'url', 'power_panel', 'rack', 'name', 'status', 'type', 'supply', 'phase', 'voltage', 'amperage',
'max_utilization', 'comments', 'tags', 'custom_fields', 'created', 'last_updated',
'connected_endpoint_type', 'connected_endpoint', 'connected_endpoint_reachable', 'cable',
'connected_endpoint_type', 'connected_endpoint', 'connected_endpoint_reachable', 'cable', 'cable_peer',
'cable_peer_type',
]