From f22bb97e5a0259aed0a3fc8573e9270d5dd52ca4 Mon Sep 17 00:00:00 2001 From: histausse Date: Wed, 2 Sep 2020 14:57:08 +0200 Subject: [PATCH] remove the second port serialiser --- topologie/api/serializers.py | 28 ---------------------------- 1 file changed, 28 deletions(-) diff --git a/topologie/api/serializers.py b/topologie/api/serializers.py index ce03a842..2006708b 100644 --- a/topologie/api/serializers.py +++ b/topologie/api/serializers.py @@ -299,31 +299,3 @@ class PortsSerializer(NamespacedHMSerializer): class Meta: model = topologie.Port fields = ("state", "port", "pretty_name", "get_port_profile") - - -class SwitchPortSerializer(serializers.ModelSerializer): - """Serialize the data about the switches""" - - ports = PortsSerializer(many=True, read_only=True) - model = ModelSwitchSerializer(read_only=True) - switchbay = SwitchBaySerializer(read_only=True) - - class Meta: - model = topologie.Switch - fields = ( - "short_name", - "model", - "switchbay", - "ports", - "ipv4", - "ipv6", - "interfaces_subnet", - "interfaces6_subnet", - "automatic_provision", - "rest_enabled", - "web_management_enabled", - "get_radius_key_value", - "get_management_cred_value", - "get_radius_servers", - "list_modules", - )