Add vfc-vnflcm queryJov responseId 59/31159/1
authorying.yunlong <ying.yunlong@zte.com.cn>
Fri, 9 Feb 2018 07:44:11 +0000 (15:44 +0800)
committerying.yunlong <ying.yunlong@zte.com.cn>
Fri, 9 Feb 2018 07:44:11 +0000 (15:44 +0800)
Change-Id: I1ecbb2c04fec1bd21cf3d9a395b8da68cdfb19ef
Issue-ID: VFC-682
Signed-off-by: ying.yunlong <ying.yunlong@zte.com.cn>
lcm/lcm/jobs/views.py
lcm/lcm/nf/vnfs/urls.py

index 3da36bf..cdd7ba4 100644 (file)
@@ -15,6 +15,7 @@
 import logging
 import traceback
 
+from drf_yasg import openapi
 from drf_yasg.utils import swagger_auto_schema
 from rest_framework import status
 from rest_framework.response import Response
@@ -30,6 +31,13 @@ logger = logging.getLogger(__name__)
 
 class JobView(APIView):
     @swagger_auto_schema(
+        manual_parameters=[
+            openapi.Parameter('responseId',
+                              openapi.IN_QUERY,
+                              "responseId",
+                              type=openapi.TYPE_INTEGER
+                              ),
+        ],
         responses={
             status.HTTP_200_OK: JobQueryRespSerializer(),
             status.HTTP_500_INTERNAL_SERVER_ERROR: "Internal error"
index a8de42b..a8348b4 100644 (file)
@@ -18,10 +18,7 @@ from lcm.nf.vnfs.views import InstantiateVnf, TerminateVnf, DeleteVnfAndQueryVnf
 
 urlpatterns = [
     url(r'^api/vnflcm/v1/vnf_instances$', CreateVnfAndQueryVnfs.as_view()),
-    url(r'^api/vnflcm/v1/vnf_instances/(?P<instanceid>[0-9a-zA-Z_-]+)/instantiate$',
-        InstantiateVnf.as_view()),
-    url(r'^api/vnflcm/v1/vnf_instances/(?P<instanceid>[0-9a-zA-Z_-]+)$',
-        DeleteVnfAndQueryVnf.as_view()),
-    url(r'^api/vnflcm/v1/vnf_instances/(?P<instanceid>[0-9a-zA-Z_-]+)/terminate$',
-        TerminateVnf.as_view()),
+    url(r'^api/vnflcm/v1/vnf_instances/(?P<instanceid>[0-9a-zA-Z_-]+)/instantiate$', InstantiateVnf.as_view()),
+    url(r'^api/vnflcm/v1/vnf_instances/(?P<instanceid>[0-9a-zA-Z_-]+)$', DeleteVnfAndQueryVnf.as_view()),
+    url(r'^api/vnflcm/v1/vnf_instances/(?P<instanceid>[0-9a-zA-Z_-]+)/terminate$', TerminateVnf.as_view()),
 ]