I have an error: name 'result' is not defined
def search(request): def get_queryset(self): query = self.request.GET.get('q') result = Shops.objects.filter(Q(city=query)) return result context={ 'shops' : result, } return render(request, 'booking/search.html',context) -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/543debc7-d517-4a7a-a9b8-f3fc7c7cc60d%40googlegroups.com.