title: Django searching function issue
body: <p>I tried implement searching function in my app , but I've got the error it's call typeError .I add the picture of this error</p>
  
  <p>views.py</p>
  
  <pre><code>from django.shortcuts import render
  from .models import Games,Game_detail,Order
  from django.shortcuts import render,get_object_or_404,redirect
  from django.views.generic import ListView,DetailView,CreateView
  from django.db.models import Q
  from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger
  
  class IndexView(ListView):
      template_name ='games/list.html'
      context_object_name = 'all_games'
      model = Games
  
      def get_queryset(self,request):
          query = request.GET.get("q")
          if query:
                  queryset_list = queryset_list.filter(
                  Q(name__icontains=query)|
                  Q(platform__icontains=query)|
                  Q(genre__icontains=query) |
                  Q(language__icontains=query)
                  ).distinct()
          return Games.objects.all()
  </code></pre>
  
  <p>list.html</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
  &lt;link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity=" sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous"&gt;
   &lt;title&gt;Page Title&lt;/title&gt;
   &lt;/head&gt;
   &lt;body&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  &lt;form method='GET' action=''&gt;
  &lt;input type='text' name='q' placeholder='Wyszukaj' value='{{ request.GET.q }}'/&gt;
  &lt;input type='submit'class="btn btn-default" value='Szukaj' /&gt;
  &lt;/form&gt;
  &lt;table class="table table-striped"&gt;
   &lt;thead&gt;
     &lt;tr&gt;
          &lt;th&gt;Nazwa&lt;/th&gt;
          &lt;/th&gt;&lt;/th&gt;
            &lt;th&gt;Platforma&lt;/th&gt;
              &lt;th&gt;Gatunek&lt;/th&gt;
              &lt;th&gt;Język&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
  &lt;tbody&gt;
  {% for obj in object_list%}
  &lt;tr&gt;
  &lt;td&gt;&lt;a href ='{%url "detail" pk=obj.pk%}'&gt;{{obj.name}}&lt;/a&gt;&lt;/td&gt;
  &lt;td&gt;{{obj.platform}}&lt;/td&gt;
  &lt;td&gt;{{obj.genre}}&lt;/td&gt;
  &lt;td&gt;{{obj.language}}&lt;/td&gt;
  &lt;/tr&gt;
  {% endfor %}
  &lt;/tbody&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>Model.py     </p>
  
  <pre><code>from django.db import models
  class Games(models.Model):
      name = models.CharField(max_length=250)
      platform = models.CharField(max_length=500)
      genre = models.CharField(max_length=100)
      language = models.CharField(max_length=100)
      image = models.ImageField(upload_to='Images_game',default='' )
    # def __str__ (self):
     # return self.Name
  
      class Game_detail(models.Model):
          game = models.ForeignKey(Games,on_delete=models.CASCADE)
          subcryption = models.TextField()
          publisher = models.CharField(max_length=250)
          date_of_publish = models.DateField()
  
      class Order(models.Model):
          person_name = models.CharField(max_length=24)
          person_surname = models.CharField(max_length=24)
          street = models.CharField(max_length=45)
          city= models.CharField(max_length=45)
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/uURf5.png" rel="nofollow noreferrer">Error issue</a></p>
  
  <p>I want write searching for this 4 values . I guess problem depend on return function could be wrong. </p>