diff options
Diffstat (limited to 'app/locations')
-rw-r--r-- | app/locations/urls.py | 2 | ||||
-rw-r--r-- | app/locations/views.py | 20 |
2 files changed, 11 insertions, 11 deletions
diff --git a/app/locations/urls.py b/app/locations/urls.py index c0ec4c4..1c8c1ed 100644 --- a/app/locations/urls.py +++ b/app/locations/urls.py @@ -20,7 +20,7 @@ urlpatterns = [ views.MapDataList.as_view(), name="mapdata" ), - re_path(r'data/(?P<id>\d+)/$', views.data_json), + #re_path(r'data/(?P<id>\d+)/$', views.data_json), path( r'', views.MapList.as_view(), diff --git a/app/locations/views.py b/app/locations/views.py index 06f7838..bf6cd84 100644 --- a/app/locations/views.py +++ b/app/locations/views.py @@ -6,7 +6,7 @@ from django.conf import settings from django.db.models import Q from jrnl.models import Entry -from projects.shortcuts import render_to_geojson +#from projects.shortcuts import render_to_geojson from sightings.models import Sighting from utils.views import PaginatedListView from .models import Country, Region, Route, Location, Track @@ -73,15 +73,15 @@ def map_data(request): ) -def data_json(request, id): - qs = Route.objects.filter(pk=id) - return render_to_geojson( - qs, - included_fields=['id', ], - geom_attribute='geometry', - mimetype='application/json', - pretty_print=True - ) +#def data_json(request, id): +# qs = Route.objects.filter(pk=id) +# return render_to_geojson( +# qs, +# included_fields=['id', ], +# geom_attribute='geometry', +# mimetype='application/json', +# pretty_print=True +# ) class LocationDetail(DetailView): |