class CircuitTerminationSerializer(serializers.ModelSerializer): site = SiteNestedSerializer() interface = InterfaceNestedSerializer() class Meta: model = CircuitTermination fields = ['id', 'term_side', 'site', 'interface', 'port_speed', 'upstream_speed', 'xconnect_id', 'pp_info']
class VLANSerializer(serializers.ModelSerializer): site = SiteNestedSerializer() group = VLANGroupNestedSerializer() tenant = TenantNestedSerializer() role = RoleNestedSerializer() class Meta: model = VLAN fields = ['id', 'site', 'group', 'vid', 'name', 'tenant', 'status', 'role', 'description', 'display_name']
class VLANSerializer(serializers.ModelSerializer): site = SiteNestedSerializer() role = RoleNestedSerializer() class Meta: model = VLAN fields = [ 'id', 'site', 'vid', 'name', 'status', 'role', 'display_name' ]
class PrefixSerializer(serializers.ModelSerializer): site = SiteNestedSerializer() vrf = VRFTenantSerializer() tenant = TenantNestedSerializer() vlan = VLANNestedSerializer() role = RoleNestedSerializer() class Meta: model = Prefix fields = ['id', 'family', 'prefix', 'site', 'vrf', 'tenant', 'vlan', 'status', 'role', 'description']
class CircuitSerializer(serializers.ModelSerializer): provider = ProviderNestedSerializer() type = CircuitTypeNestedSerializer() site = SiteNestedSerializer() interface = InterfaceNestedSerializer() class Meta: model = Circuit fields = [ 'id', 'cid', 'provider', 'type', 'site', 'interface', 'install_date', 'port_speed', 'commit_rate', 'xconnect_id', 'comments' ]
class CircuitSerializer(CustomFieldSerializer, serializers.ModelSerializer): provider = ProviderNestedSerializer() type = CircuitTypeNestedSerializer() tenant = TenantNestedSerializer() site = SiteNestedSerializer() interface = InterfaceNestedSerializer() class Meta: model = Circuit fields = [ 'id', 'cid', 'provider', 'type', 'tenant', 'site', 'interface', 'install_date', 'port_speed', 'upstream_speed', 'commit_rate', 'xconnect_id', 'comments', 'custom_fields' ]
class VLANGroupSerializer(serializers.ModelSerializer): site = SiteNestedSerializer() class Meta: model = VLANGroup fields = ['id', 'name', 'slug', 'site']