Right. If you are looking for more complex queries take a look at Q
http://docs.djangoproject.com/en/dev/topics/db/queries/#complex-lookups-with-q-objects
On Aug 3, 6:40 pm, selcukcihan wrote:
> I need to get the filtering criteria from the request, is that right?
>
> On
I need to get the filtering criteria from the request, is that right?
On Aug 3, 2:24 pm, Peter Bengtsson wrote:
> Untested but should work (in admin.py):
>
> class ThingAdmin(admin.ModelAdmin):
> def queryset(self, request):
> qs = super(ThingAdmin,
Untested but should work (in admin.py):
class ThingAdmin(admin.ModelAdmin):
def queryset(self, request):
qs = super(ThingAdmin, self).queryset(request)
qs = qs.filter(some_integer_field__gt=10)
return qs
admin.site.register(Thing, ThingAdmin)
On 3 Aug, 10:52,
Hi, is there a ready to go solution within django for providing
complex filters(besides the date filters and others) on models within
the admin? For instance, there is a model with an integer field, i
would like to be able to apply filters of the form "greater than or
equal to" or "between this
4 matches
Mail list logo