I
I
int22h2012-12-20 19:37:03
Django
int22h, 2012-12-20 19:37:03

Why bother with Django's complicated profile system?

Django has a big problem with users and profiles. You constantly have to fence the system of accounts, profiles, use signals for various events. Why all these applications, if you can inherit from User in your application, without third-party applications that implement profiles that are created during user creation. In different projects I used django-userena, django-profiles-now I am writing a new project and I thought, why all this?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
B
barker, 2012-12-20
@barker

Well, use inheritance, I also do this most often. Profiles are generally a moronic thing (with the exception of places where they can really be useful). There are some subtleties with the inherited in the admin panel, perhaps, but everything is solvable. In 1.5, which is already right on the nose, in general, its own model of the user is a sparkle.

K
kozztik, 2013-01-15
@kozztik

Everything from the fact that using the standard model you get easy authorization and so on. If you inherit from the standard one, as I understand it, you need to do a little shamanism in order to correctly set and check authorization for request.user, and everything is out of the box.
Although I myself think that it would be necessary to inherit, but now there are so many dependencies in the project that my head is spinning from the thought that all references to my model would be rearranged - the base floor needs to be redrawn.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question