Opened 16 years ago

Closed 16 years ago

Last modified 13 years ago

#8109 closed (duplicate)

list_filter on BooleanField in admin site always displays True objects

Reported by: Giorgio Salluzzo Owned by: nobody
Component: contrib.admin Version: dev
Severity: Keywords: admin list filter boolean booleanfield
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

With last SVN I'm getting an error filtering on a boolean field.
In any case I can't list False items because SQL contains always "= true".

This is one of the queries made with the following GET on the filter:
/admin/products/nsale/?is_activeexact=0

SELECT COUNT(*) FROM "products_nsale" WHERE "products_nsale"."is_active" = true

My dev system is an Ubuntu 8.04 with Python 2.5, psycopg2 and Postgresql 8.3.

Change History (3)

comment:1 by ElliottM, 16 years ago

Component: UncategorizedAdmin interface
Keywords: admin list filter boolean booleanfield added
milestone: 1.0
Summary: list_filter on BooleanFieldlist_filter on BooleanField in admin site always displays True objects
Triage Stage: UnreviewedAccepted

This happens for me in mysql, and the actual database backend is filtering correctly for me, so it has to be the admin site.

comment:2 by Brian Rosner, 16 years ago

Resolution: duplicate
Status: newclosed

Duplicate of #8101

comment:3 by Jacob, 13 years ago

milestone: 1.0

Milestone 1.0 deleted

Note: See TracTickets for help on using tickets.
Back to Top