Thanks for your responses. I don't think my question was all that clear, however, thanks to Ivan I've found the similar discussion topic he referenced:
http://groups.google.com/group/django-users/browse_thread/thread/d1649d9d6153b948/233ca8422a73cd3e?lnk=gst&q=class+static+manager+methods#233ca8422a73cd3e Dave On Feb 24, 4:04 pm, Ivan Illarionov <[EMAIL PROTECTED]> wrote: > > def create_user(self, username, email, password=None): > > def make_random_password(self, length=10, > > allowed_chars='abcdefghjkmnpqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ23456789'): > > > These two methods seem to involve situations where they need to act on > > a model, but the object instance hasn't been created yet. Should > > managers always be used for this? > > Dave, these methods are methods of "UserManger" which is a Manager. > The Model that uses this Manager is called "User" and is a little > deeper in the code. > It looks that you misunderstood the code. > > > Have people placed similar functionality within the model classes > > directly? I suppose it depends on whether you need the functionality > > in absence of an object instance... > > There was a discussion about this rescently. Classmethods and > staticmethods will work, as well as plain module-level functions, but > a Manager is a preferred way in Django. --~--~---------~--~----~------------~-------~--~----~ 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?hl=en -~----------~----~----~----~------~----~------~--~---