Electronics & Programming

develissimo

Open Source electronics development and programming

  • You are not logged in.
  • Root
  • » Django
  • » Records detected by admin site, but not displayed? [RSS Feed]

#1 Dec. 2, 2010 14:15:55

Sithembewena L.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

Records detected by admin site, but not displayed?


Hi all,

I have an admin site enabled for my Django project. For some reason, some
records are no longer displayed (they were displayed just fine before).

Tried restarting the dev server to no avail.

Please see the attached screen dump? What could be causing this?

--
Regards,
Sithembewena Lloyd Dube

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.<<attachment: missing_items.png>>

Offline

#2 Dec. 2, 2010 16:46:10

w.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

Records detected by admin site, but not displayed?


On Dec 2, 8:15 am, Sithembewena Lloyd Dube <zebr...@gmail.com> wrote:
> Hi all,
>
> I have an admin site enabled for my Django project. For some reason, some
> records are no longer displayed (they were displayed just fine before).
>
> Tried restarting the dev server to no avail.
>
> Please see the attached screen dump? What could be causing this?

Have you made any recent changes? Have you overridden any admin
templates? Did you specify anything in a Blog Admin class?

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

#3 Dec. 3, 2010 08:20:21

Sithembewena L.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

Records detected by admin site, but not displayed?


Hi Wayne,

Thanks for responding. This actually helped me to trace the problem. Yes, I
did extend the admin User (default django user) as follows - this is in
models.py:

from django.contrib.auth.models import User

class BlogUser(models.Model):
user = models.ForeignKey(User, unique=True)
avatar = ThumbnailerImageField(upload_to='avatars/users', blank=False)

The point is that I wanted the default user to have an avatar by 'extending'
the model.


I then have a BlogPost class with a field as follows:

author = models.ForeignKey(User)

and a BlogComment class with a field as follows:

blog_post = models.ForeignKey(BlogPost)

If I display a Blog Post by the default user and wish to show their avatar,
I need to map the author foreignkey relationship in the BlogPost model to
the extension model, BlogUser because that is where the field is.

Unfortunately, this seems to break the admin. Is there a way I can get the
extension model in code from the default, or extended, model?

Thanks,
Lloyd


On Thu, Dec 2, 2010 at 6:46 PM, wayne <wayne.tuxro...@gmail.com> wrote:

> On Dec 2, 8:15 am, Sithembewena Lloyd Dube <zebr...@gmail.com> wrote:
> > Hi all,
> >
> > I have an admin site enabled for my Django project. For some reason, some
> > records are no longer displayed (they were displayed just fine before).
> >
> > Tried restarting the dev server to no avail.
> >
> > Please see the attached screen dump? What could be causing this?
>
> Have you made any recent changes? Have you overridden any admin
> templates? Did you specify anything in a Blog Admin class?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com<django-users%2bunsubscr...@googlegroups.com>
> .
> For more options, visit this group at
>http://groups.google.com/group/django-users?hl=en.
>
>


--
Regards,
Sithembewena Lloyd Dube

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

  • Root
  • » Django
  • » Records detected by admin site, but not displayed? [RSS Feed]

Board footer

Moderator control

Enjoy the 21st of August
PoweredBy

The Forums are managed by develissimo stuff members, if you find any issues or misplaced content please help us to fix it. Thank you! Tell us via Contact Options
Leave a Message
Welcome to Develissimo Live Support