Missing Records in Admin Interface [SOLVED]

25 views
Skip to first unread message

Jashugan

unread,
Jul 14, 2008, 9:49:47 PM7/14/08
to Django users
I had an interesting problem today.

I had some records that were missing in the auto-admin list of one of
my models. The count was correct, but the records were simply not
displayed. When I did a select query from the command line they all
showed up just fine; some of them were simply missing from the auto-
admin list.

I finally isolated the problem to a missing record a couple of foreign
key hops away. For example...

Project1 <-- Product1 <-- Model1 (visible)
Project2 (not created) <-- Product2 <-- Model2 (missing)

So Model2 wasn't being displayed because Project2 didn't exist. I
think this had something to do with my unicode method on the Product
because I referenced the Project in it. It was probably throwing an
error, but for some reason Django was just ignoring it.

In any case, I hope this helps someone.
Reply all
Reply to author
Forward
0 new messages