Skip to content

Commit

Permalink
Refactorise les URL de recherche
Browse files Browse the repository at this point in the history
  • Loading branch information
Arnaud-D committed May 7, 2022
1 parent ad855f7 commit dc4219d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
12 changes: 7 additions & 5 deletions zds/searchv2/urls.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
from django.urls import re_path
from django.urls import path
from zds.searchv2.views import SearchView, opensearch, SimilarTopicsView, SuggestionContentView

app_name = "search"

urlpatterns = [
re_path(r"^$", SearchView.as_view(), name="query"),
re_path(r"^sujets-similaires/$", SimilarTopicsView.as_view(), name="similar"),
re_path(r"^suggestion-contenu/$", SuggestionContentView.as_view(), name="suggestion"),
re_path(r"^opensearch\.xml$", opensearch, name="opensearch"),
path("", SearchView.as_view(), name="query"),
path("sujets-similaires/", SimilarTopicsView.as_view(), name="similar"),
path("suggestion-contenu/", SuggestionContentView.as_view(), name="suggestion"),
path("opensearch.xml", opensearch, name="opensearch"),
]
2 changes: 1 addition & 1 deletion zds/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ def location(self, item):
re_path(r"^admin/", admin.site.urls),
re_path(r"^pages/", include(("zds.pages.urls", ""))),
re_path(r"^galerie/", include(("zds.gallery.urls", ""))),
re_path(r"^rechercher/", include(("zds.searchv2.urls", "zds.searchv2"), namespace="search")),
path("rechercher/", include("zds.searchv2.urls")),
re_path(r"^munin/", include(("zds.munin.urls", ""))),
re_path(r"^mise-en-avant/", include(("zds.featured.urls", ""))),
re_path(r"^notifications/", include(("zds.notification.urls", ""))),
Expand Down

0 comments on commit dc4219d

Please sign in to comment.