diff options
Diffstat (limited to 'app/locations/admin.py')
-rw-r--r-- | app/locations/admin.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/app/locations/admin.py b/app/locations/admin.py index c3419b1..4a52778 100644 --- a/app/locations/admin.py +++ b/app/locations/admin.py @@ -3,6 +3,7 @@ from django.contrib.gis.admin import OSMGeoAdmin from locations.models import Region, Country, Location, State, Route, CheckIn from utils.widgets import OLAdminBase +from utils.util import get_latlon class RegionAdmin(OSMGeoAdmin): list_display = ('name', 'slug') @@ -183,8 +184,7 @@ class LocationAdmin(OSMGeoAdmin): }), ) # options for OSM map Using custom ESRI topo map - default_lon = -9285175 - default_lat = 4025046 + default_lat, default_lon = get_latlon() default_zoom = 6 units = True scrollable = False @@ -193,6 +193,9 @@ class LocationAdmin(OSMGeoAdmin): map_template = 'gis/admin/osm.html' openlayers_url = '/static/admin/js/OpenLayers.js' + class Media: + js = ('next-prev-links.js',) + admin.site.register(Location, LocationAdmin) |