mirror of
https://github.com/pacnpal/thrillwiki_django_no_react.git
synced 2025-12-22 04:51:09 -05:00
Enhance park search with autocomplete and improved filtering options
Introduce autocomplete for park searches, optimize park data fetching with select_related and prefetch_related, add new API endpoints for autocomplete and quick filters, and refactor the park list view to use new Django Cotton components for a more dynamic and user-friendly experience. Replit-Commit-Author: Agent Replit-Commit-Session-Id: c446bc9e-66df-438c-a86c-f53e6da13649 Replit-Commit-Checkpoint-Type: intermediate_checkpoint
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
from django.urls import path, include
|
||||
from . import views, views_search
|
||||
from . import views, views_search, views_autocomplete
|
||||
from apps.rides.views import ParkSingleCategoryListView
|
||||
from .views_roadtrip import (
|
||||
RoadTripPlannerView,
|
||||
@@ -30,6 +30,9 @@ urlpatterns = [
|
||||
path("areas/", views.get_park_areas, name="get_park_areas"),
|
||||
path("suggest_parks/", views_search.suggest_parks, name="suggest_parks"),
|
||||
path("search/", views.search_parks, name="search_parks"),
|
||||
# Enhanced search endpoints
|
||||
path("api/autocomplete/", views_autocomplete.ParkAutocompleteView.as_view(), name="park_autocomplete"),
|
||||
path("api/quick-filters/", views_autocomplete.QuickFilterSuggestionsView.as_view(), name="quick_filter_suggestions"),
|
||||
# Road trip planning URLs
|
||||
path("roadtrip/", RoadTripPlannerView.as_view(), name="roadtrip_planner"),
|
||||
path("roadtrip/create/", CreateTripView.as_view(), name="roadtrip_create"),
|
||||
|
||||
Reference in New Issue
Block a user