Thank you, thank you, thank you.

On Apr 5, 2006, at 5:10 PM, arthur debert wrote:
> I guess what you are looking for is:
> u = User.objects.get(username='namehere')
>
>  but you could also:
>
> 1) fire the shell (cd to your project dir) then:
>    python manage.py shell
>    from django.contrib.auth.models import User
>    dir(User) or dir(User,objetcts.all()[0])
The second one works. I forgot that attributes wouldn't show up on  
classes, just instances.

> 2) on the admin site, on the top bar there's a "Documentation" link
> (mut have docutils installed ) this is very usefull for newbies, I use
> it all the time. As a side bonus you get to see ForeignKey and
> ManyToMany methods also.
Oooooh. That *is* nice.

> 3) checkout the source itself, since you are using this sintax you're
> probably using magic-removal, then you can see the python module in :
> django/contrib/auth/models.py
This is where I finally found the answer. A bit of a pain, but not  
too awful.
Isn't there a Javadoc equivalent for Python?

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~----------~----~----~----~------~----~------~--~---

Reply via email to