fix some issues when c3nav is setup from ground up

This commit is contained in:
Laura Klünder 2018-11-16 00:52:13 +01:00
parent 417fd9514e
commit 27c833b3ef
3 changed files with 8 additions and 3 deletions

View file

@ -114,6 +114,9 @@ def map_index(request, mode=None, slug=None, slug2=None, details=None, options=N
})
initial_bounds = settings.INITIAL_BOUNDS
if not initial_bounds:
initial_bounds = (0, 0, 10, 10)
ctx = {
'bounds': json.dumps(Source.max_bounds(), separators=(',', ':')),
'levels': json.dumps(tuple((level.pk, level.short_label) for level in levels.values()), separators=(',', ':')),