Skip to content

Commit 6e45870

Browse files
committed
fix merge
1 parent b791207 commit 6e45870

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

djangocms_rest/schemas.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,18 @@ def method_schema_decorator(method):
6969
]
7070
)
7171

72+
extend_page_search_schema = extend_schema(
73+
parameters=[
74+
OpenApiParameter(
75+
name="q",
76+
type=OpenApiTypes.STR,
77+
location=OpenApiParameter.QUERY,
78+
description="Search for an exact match of the search term to find pages by title, page_title, menu_title, or meta_description",
79+
required=False,
80+
),
81+
]
82+
)
83+
7284
except ImportError:
7385

7486
def method_schema_decorator(method):

djangocms_rest/views.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
get_site_filtered_queryset,
3333
)
3434
from djangocms_rest.views_base import BaseAPIView, BaseListAPIView
35-
from djangocms_rest.schemas import extend_placeholder_schema, menu_schema_class
35+
from djangocms_rest.schemas import extend_placeholder_schema, extend_page_search_schema, menu_schema_class
3636

3737
# Generate the plugin definitions once at module load time
3838
# This avoids the need to import the plugin definitions in every view

0 commit comments

Comments
 (0)