Permalink
Browse files

Merge branch '2.0' of file:///home/git/repositories/farmsubsidy into 2.0

  • Loading branch information...
2 parents 193afe4 + 3aec193 commit baf2a21580af7bbe282566e9a94b3d3b1ee840c8 Simon Roe committed Dec 6, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 web/data/views.py
View
@@ -192,7 +192,7 @@ def recipient(request, country, recipient_id, name):
try:
georecipient = models.GeoRecipient.objects.get(pk=recipient.pk)
- closest = models.GeoRecipient.objects.distance(georecipient.location).order_by('distance')[:5]
+ closest = models.GeoRecipient.objects.filter(location__dwithin=(georecipient.location, 20)).distance(georecipient.location).order_by('distance')[:5]
except:
closest = None

0 comments on commit baf2a21

Please sign in to comment.