Code Review
/
modeling
/
etsicatalog.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
update swagger info, add tags for swagger_auto_schema
[modeling/etsicatalog.git]
/
catalog
/
packages
/
views
/
pnf_descriptor_views.py
diff --git
a/catalog/packages/views/pnf_descriptor_views.py
b/catalog/packages/views/pnf_descriptor_views.py
index
9120980
..
381b557
100644
(file)
--- a/
catalog/packages/views/pnf_descriptor_views.py
+++ b/
catalog/packages/views/pnf_descriptor_views.py
@@
-39,6
+39,7
@@
logger = logging.getLogger(__name__)
@swagger_auto_schema(
method='GET',
operation_description="Query a PNFD",
@swagger_auto_schema(
method='GET',
operation_description="Query a PNFD",
+ tags=["PNFD API"],
request_body=no_body,
responses={
status.HTTP_200_OK: PnfdInfoSerializer(),
request_body=no_body,
responses={
status.HTTP_200_OK: PnfdInfoSerializer(),
@@
-49,6
+50,7
@@
logger = logging.getLogger(__name__)
@swagger_auto_schema(
method='DELETE',
operation_description="Delete a PNFD",
@swagger_auto_schema(
method='DELETE',
operation_description="Delete a PNFD",
+ tags=["PNFD API"],
request_body=no_body,
responses={
status.HTTP_204_NO_CONTENT: "No content",
request_body=no_body,
responses={
status.HTTP_204_NO_CONTENT: "No content",
@@
-74,6
+76,7
@@
def pnfd_info_rd(request, **kwargs): # TODO
@swagger_auto_schema(
method='POST',
operation_description="Create a PNFD",
@swagger_auto_schema(
method='POST',
operation_description="Create a PNFD",
+ tags=["PNFD API"],
request_body=CreatePnfdInfoRequestSerializer(),
responses={
status.HTTP_201_CREATED: PnfdInfoSerializer(),
request_body=CreatePnfdInfoRequestSerializer(),
responses={
status.HTTP_201_CREATED: PnfdInfoSerializer(),
@@
-83,6
+86,7
@@
def pnfd_info_rd(request, **kwargs): # TODO
@swagger_auto_schema(
method='GET',
operation_description="Query multiple PNFDs",
@swagger_auto_schema(
method='GET',
operation_description="Query multiple PNFDs",
+ tags=["PNFD API"],
request_body=no_body,
responses={
status.HTTP_200_OK: PnfdInfosSerializer(),
request_body=no_body,
responses={
status.HTTP_200_OK: PnfdInfosSerializer(),
@@
-107,6
+111,7
@@
def pnf_descriptors_rc(request):
@swagger_auto_schema(
method='PUT',
operation_description="Upload PNFD content",
@swagger_auto_schema(
method='PUT',
operation_description="Upload PNFD content",
+ tags=["PNFD API"],
request_body=no_body,
responses={
status.HTTP_204_NO_CONTENT: "No content",
request_body=no_body,
responses={
status.HTTP_204_NO_CONTENT: "No content",
@@
-116,6
+121,7
@@
def pnf_descriptors_rc(request):
@swagger_auto_schema(
method='GET',
operation_description="Fetch PNFD content",
@swagger_auto_schema(
method='GET',
operation_description="Fetch PNFD content",
+ tags=["PNFD API"],
request_body=no_body,
responses={
status.HTTP_204_NO_CONTENT: 'PNFD file',
request_body=no_body,
responses={
status.HTTP_204_NO_CONTENT: 'PNFD file',
@@
-145,6
+151,7
@@
def pnfd_content_ru(request, **kwargs):
@swagger_auto_schema(
method='POST',
operation_description="Parse PNF model",
@swagger_auto_schema(
method='POST',
operation_description="Parse PNF model",
+ tags=["Parser API"],
request_body=ParseModelRequestSerializer,
responses={
status.HTTP_202_ACCEPTED: ParseModelResponseSerializer,
request_body=ParseModelRequestSerializer,
responses={
status.HTTP_202_ACCEPTED: ParseModelResponseSerializer,