app/soc/views/models/base.py
changeset 1790 7655a46dcfa3
parent 1784 d5dacf2be926
child 1796 5cd78a7aacdd
equal deleted inserted replaced
1789:6f112b2ebd1f 1790:7655a46dcfa3
   640     filter = {}
   640     filter = {}
   641     for key in request.GET.keys():
   641     for key in request.GET.keys():
   642       # need to use getlist as we want to support multiple values
   642       # need to use getlist as we want to support multiple values
   643       filter[key] = request.GET.getlist(key)
   643       filter[key] = request.GET.getlist(key)
   644 
   644 
   645     entities = logic.getForFields(filter=filter, limit=1000)
   645     query = logic.getQueryForFields(filter=filter)
       
   646     entities = logic.getAll(query)
       
   647 
   646     data = [i.toDict() for i in entities]
   648     data = [i.toDict() for i in entities]
   647 
   649 
   648     return self.json(request, data)
   650     return self.json(request, data)
   649 
   651 
   650   def json(self, request, data):
   652   def json(self, request, data):