Change-Id: I34083b08021bc36287449695caa2a80ca127b7dc
Issue-ID: VFC-679
Signed-off-by: ying.yunlong <ying.yunlong@zte.com.cn>
# limitations under the License.
from django.conf.urls import url
-from rest_framework.urlpatterns import format_suffix_patterns
from res.resources import views
url(r'^api/vnfres/v1/(?P<vnfInstanceId>[0-9a-zA-Z\-\_]+)/cps$', views.getCps.as_view(), name='get_cps'),
url(r'^api/vnfres/v1/(?P<vnfInstanceId>[0-9a-zA-Z\-\_]+)/volumes$', views.getVolumes.as_view(), name='get_volumes'),
]
-
-urlpatterns = format_suffix_patterns(urlpatterns)
import logging
+from drf_yasg.utils import swagger_auto_schema
+from rest_framework import status
from rest_framework.views import APIView
from rest_framework.response import Response
class SampleList(APIView):
- def get(self, request, format=None):
+ @swagger_auto_schema(
+ responses={
+ status.HTTP_200_OK: 'Successfully'})
+ def get(self, request):
logger.debug("get")
return Response({"status": "active"})