Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
django
Commits
89f17e7c
Kaydet (Commit)
89f17e7c
authored
Agu 15, 2016
tarafından
Daniel Wiesmann
Kaydeden (comit)
Tim Graham
Agu 15, 2016
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fixed #27014 -- Fixed annotations with database functions on PostGIS.
Thanks Sean Mc Allister for providing a test.
üst
48ede589
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
1 deletion
+7
-1
adapter.py
django/contrib/gis/db/backends/postgis/adapter.py
+1
-1
1.10.1.txt
docs/releases/1.10.1.txt
+3
-0
tests.py
tests/gis_tests/geogapp/tests.py
+3
-0
No files found.
django/contrib/gis/db/backends/postgis/adapter.py
Dosyayı görüntüle @
89f17e7c
...
...
@@ -15,7 +15,7 @@ class PostGISAdapter(object):
"""
Initialize on the spatial object.
"""
self
.
is_geometry
=
isinstance
(
obj
,
Geometry
)
self
.
is_geometry
=
isinstance
(
obj
,
(
Geometry
,
PostGISAdapter
)
)
# Getting the WKB (in string form, to allow easy pickling of
# the adaptor) and the SRID from the geometry or raster.
...
...
docs/releases/1.10.1.txt
Dosyayı görüntüle @
89f17e7c
...
...
@@ -48,3 +48,6 @@ Bugfixes
* Fixed ``ClearableFileInput`` to avoid the ``required`` HTML attribute when
initial data exists (:ticket:`27037`).
* Fixed annotations with database functions when combined with lookups on
PostGIS (:ticket:`27014`).
tests/gis_tests/geogapp/tests.py
Dosyayı görüntüle @
89f17e7c
...
...
@@ -142,6 +142,9 @@ class GeographyFunctionTests(TestCase):
qs
=
Zipcode
.
objects
.
annotate
(
distance
=
Distance
(
'poly'
,
htown
.
point
))
for
z
,
ref
in
zip
(
qs
,
ref_dists
):
self
.
assertAlmostEqual
(
z
.
distance
.
m
,
ref
,
2
)
# Distance function in combination with a lookup.
hzip
=
Zipcode
.
objects
.
get
(
code
=
'77002'
)
self
.
assertEqual
(
qs
.
get
(
distance__lte
=
0
),
hzip
)
@skipUnlessDBFeature
(
"has_Area_function"
,
"supports_distance_geodetic"
)
def
test_geography_area
(
self
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment