Loading django/contrib/gis/templates/gis/openlayers.html +3 −2 Original line number Diff line number Diff line <style type="text/css">{% block map_css %}{% load i18n static %}{% get_current_language_bidi as LANGUAGE_BIDI %} {% load i18n l10n static %} <style type="text/css">{% block map_css %}{% get_current_language_bidi as LANGUAGE_BIDI %} #{{ id }}_map { width: {{ map_width }}px; height: {{ map_height }}px; } #{{ id }}_map .aligned label { float: inherit; } #{{ id }}_div_map { position: relative; vertical-align: top; float: {{ LANGUAGE_BIDI|yesno:"right,left" }}; } Loading @@ -25,7 +26,7 @@ id: '{{ id }}', map_id: '{{ id }}_map', map_options: map_options, map_srid: {{ map_srid }}, map_srid: {{ map_srid|unlocalize }}, name: '{{ name }}' }; {% endblock %} Loading docs/releases/1.8.9.txt +3 −0 Original line number Diff line number Diff line Loading @@ -34,3 +34,6 @@ Bugfixes * Fixed a regression in Django 1.8.5 that broke copying a ``SimpleLazyObject`` with ``copy.copy()`` (:ticket:`26122`). * Fixed the ``contrib.gis`` map widgets when using ``USE_THOUSAND_SEPARATOR=True`` (:ticket:`20415`). tests/gis_tests/test_geoforms.py +4 −1 Original line number Diff line number Diff line Loading @@ -2,7 +2,7 @@ from unittest import skipUnless from django.contrib.gis.gdal import HAS_GDAL from django.forms import ValidationError from django.test import SimpleTestCase, skipUnlessDBFeature from django.test import SimpleTestCase, override_settings, skipUnlessDBFeature from django.utils import six from django.utils.html import escape Loading Loading @@ -154,6 +154,7 @@ class SpecializedFieldTest(SimpleTestCase): self.assertTrue(form_instance.is_valid()) rendered = form_instance.as_p() self.assertIn('new MapWidget(options);', rendered) self.assertIn('map_srid: 4326,', rendered) self.assertIn('gis/js/OLMapWidget.js', str(form_instance.media)) def assertTextarea(self, geom, rendered): Loading @@ -163,6 +164,8 @@ class SpecializedFieldTest(SimpleTestCase): self.assertIn('required', rendered) self.assertIn(geom.wkt, rendered) # map_srid in operlayers.html template must not be localized. @override_settings(USE_L10N=True, USE_THOUSAND_SEPARATOR=True) def test_pointfield(self): class PointForm(forms.Form): p = forms.PointField() Loading Loading
django/contrib/gis/templates/gis/openlayers.html +3 −2 Original line number Diff line number Diff line <style type="text/css">{% block map_css %}{% load i18n static %}{% get_current_language_bidi as LANGUAGE_BIDI %} {% load i18n l10n static %} <style type="text/css">{% block map_css %}{% get_current_language_bidi as LANGUAGE_BIDI %} #{{ id }}_map { width: {{ map_width }}px; height: {{ map_height }}px; } #{{ id }}_map .aligned label { float: inherit; } #{{ id }}_div_map { position: relative; vertical-align: top; float: {{ LANGUAGE_BIDI|yesno:"right,left" }}; } Loading @@ -25,7 +26,7 @@ id: '{{ id }}', map_id: '{{ id }}_map', map_options: map_options, map_srid: {{ map_srid }}, map_srid: {{ map_srid|unlocalize }}, name: '{{ name }}' }; {% endblock %} Loading
docs/releases/1.8.9.txt +3 −0 Original line number Diff line number Diff line Loading @@ -34,3 +34,6 @@ Bugfixes * Fixed a regression in Django 1.8.5 that broke copying a ``SimpleLazyObject`` with ``copy.copy()`` (:ticket:`26122`). * Fixed the ``contrib.gis`` map widgets when using ``USE_THOUSAND_SEPARATOR=True`` (:ticket:`20415`).
tests/gis_tests/test_geoforms.py +4 −1 Original line number Diff line number Diff line Loading @@ -2,7 +2,7 @@ from unittest import skipUnless from django.contrib.gis.gdal import HAS_GDAL from django.forms import ValidationError from django.test import SimpleTestCase, skipUnlessDBFeature from django.test import SimpleTestCase, override_settings, skipUnlessDBFeature from django.utils import six from django.utils.html import escape Loading Loading @@ -154,6 +154,7 @@ class SpecializedFieldTest(SimpleTestCase): self.assertTrue(form_instance.is_valid()) rendered = form_instance.as_p() self.assertIn('new MapWidget(options);', rendered) self.assertIn('map_srid: 4326,', rendered) self.assertIn('gis/js/OLMapWidget.js', str(form_instance.media)) def assertTextarea(self, geom, rendered): Loading @@ -163,6 +164,8 @@ class SpecializedFieldTest(SimpleTestCase): self.assertIn('required', rendered) self.assertIn(geom.wkt, rendered) # map_srid in operlayers.html template must not be localized. @override_settings(USE_L10N=True, USE_THOUSAND_SEPARATOR=True) def test_pointfield(self): class PointForm(forms.Form): p = forms.PointField() Loading