diff options
-rw-r--r-- | lcm/lcm/nf/vnfs/serializers.py | 21 | ||||
-rw-r--r-- | lcm/lcm/settings.py | 2 |
2 files changed, 10 insertions, 13 deletions
diff --git a/lcm/lcm/nf/vnfs/serializers.py b/lcm/lcm/nf/vnfs/serializers.py index 50879a19..b7fe9e6f 100644 --- a/lcm/lcm/nf/vnfs/serializers.py +++ b/lcm/lcm/nf/vnfs/serializers.py @@ -337,13 +337,6 @@ class ExtVirtualLinkSerizlizer(serializers.Serializer): allow_null=True) -class ExtVirtualLinksSerializer(serializers.ListSerializer): - child = ExtVirtualLinkSerizlizer( - help_text="extVirtualLink", - required=False, - allow_null=True) - - class AdditionalParamsSerializer(serializers.Serializer): inputs = serializers.DictField( help_text="inputs", @@ -352,8 +345,11 @@ class AdditionalParamsSerializer(serializers.Serializer): allow_blank=True), required=False, allow_null=True) - extVirtualLinks = ExtVirtualLinksSerializer( - help_text="extVirtualLinks", required=False, allow_null=True) + extVirtualLinks = serializers.ListSerializer( + help_text="extVirtualLinks", + child=ExtVirtualLinkSerizlizer(help_text="extVirtualLinks", required=False, allow_null=True), + required=False, + allow_null=True) class InstantiateVnfRequestSerializer(serializers.Serializer): @@ -372,8 +368,11 @@ class InstantiateVnfRequestSerializer(serializers.Serializer): required=True, max_length=255, allow_null=True) - extVirtualLinks = ExtVirtualLinksSerializer( - help_text="extVirtualLinks", required=False, allow_null=True) + extVirtualLinks = serializers.ListSerializer( + help_text="extVirtualLinks", + child=ExtVirtualLinkSerizlizer(help_text="extVirtualLinks", required=False, allow_null=True), + required=False, + allow_null=True) additionalParams = AdditionalParamsSerializer( help_text="additionalParams", required=False, allow_null=True) diff --git a/lcm/lcm/settings.py b/lcm/lcm/settings.py index 9de0b9df..85e89819 100644 --- a/lcm/lcm/settings.py +++ b/lcm/lcm/settings.py @@ -71,8 +71,6 @@ REST_FRAMEWORK = { 'DEFAULT_PARSER_CLASSES': ( 'rest_framework.parsers.JSONParser', 'rest_framework.parsers.MultiPartParser', - # 'rest_framework.parsers.FormParser', - # 'rest_framework.parsers.FileUploadParser', ) } |