8
0
Fork 0
mirror of https://gitlab2.federez.net/re2o/re2o synced 2024-11-23 11:53:12 +00:00

Correction : la variable type a changé de nom

This commit is contained in:
Gabriel Detraz 2020-02-03 15:38:48 +01:00 committed by chirac
parent 9fdf6056ce
commit f5d1412635

View file

@ -48,7 +48,7 @@ class IpTypeField(serializers.RelatedField):
""" Serializer for an IpType object field """
def to_representation(self, value):
return value.type
return str(value)
def to_internal_value(self, data):
pass
@ -164,7 +164,7 @@ class TypeSerializer(serializers.ModelSerializer):
class Meta:
model = IpType
fields = (
"type",
"name",
"extension",
"domaine_ip_start",
"domaine_ip_stop",