update location filter for sight seeing
This commit is contained in:
@ -140,9 +140,9 @@ def LocationInBound(request):
|
||||
locs = Location.objects.filter(~Q(cp=0), geom__within=pl, category=cat, event_name__isnull=True)
|
||||
else:
|
||||
if grp:
|
||||
locs = Location.objects.filter(geom__within=pl, category=cat, event_name__isnull=True, group__contains=grp)
|
||||
locs = Location.objects.filter(geom__within=pl, category=cat, event_name__isnull=True, group__contains=grp, location_name__contains='観光')
|
||||
else:
|
||||
locs = Location.objects.filter(geom__within=pl, category=cat, event_name__isnull=True)
|
||||
locs = Location.objects.filter(geom__within=pl, category=cat, event_name__isnull=True, location_name__contains='観光')
|
||||
else:
|
||||
if is_rog:
|
||||
if grp:
|
||||
@ -151,9 +151,9 @@ def LocationInBound(request):
|
||||
locs = Location.objects.filter(~Q(cp=0), geom__within=pl, event_name__isnull=True)
|
||||
else:
|
||||
if grp:
|
||||
locs = Location.objects.filter(geom__within=pl, event_name__isnull=True, group__contains=grp)
|
||||
locs = Location.objects.filter(geom__within=pl, event_name__isnull=True, group__contains=grp, location_name__contains='観光')
|
||||
else:
|
||||
locs = Location.objects.filter(geom__within=pl, event_name__isnull=True)
|
||||
locs = Location.objects.filter(geom__within=pl, event_name__isnull=True, location_name__contains='観光')
|
||||
if len(locs) > 50:
|
||||
return JsonResponse({"too_many_points": True}, safe=False, status=500)
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user