Ask this on django-users
On Thu, Jul 5, 2012 at 11:50 AM, Tsachi <tsachi.shu...@gmail.com> wrote: > Hi, > I have a simple question, which I couldn't find an answer to it anywhere: > In a django project I'm working on, a deleted user is marked as * > is_active=False*. > *I need to custom the User manager to filter out all is_active=Falseusers. > * > This is a project-wide requirement. In other words: I don't need to see > deleted users in any case. > I do, however, need them to stay in the DB, for other reasons: data > integrity, re-registration prevention (on DB level). > > I want to modify the *objects* manager, because: > a. the project already exists, so it's gonna make a lot of work finding > all the places with *objects* and replacing them with another manager. > b. A proxy model will require me to replace all *user *occurences and > replace them (also, I'm not sure a proxied model can be used with *request > *). > c. There are places where functions like *get_object_or_404()* are used. > > So, what's the correct way of modifying the User *objects* manager to > exclude *is_active=False* users? > > Thanks, > Tsachi > > -- > You received this message because you are subscribed to the Google Groups > "Django developers" group. > To view this discussion on the web visit > https://groups.google.com/d/msg/django-developers/-/FStQ6EMNTREJ. > To post to this group, send email to django-developers@googlegroups.com. > To unsubscribe from this group, send email to > django-developers+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/django-developers?hl=en. > -- You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com. To unsubscribe from this group, send email to django-developers+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-developers?hl=en.