Hi,
i'm trying to add users without using catwalk and without shell, just
code.
so what i'm trying: (adduser_func is called by a form)

    def adduser_func(self, name="", passwd="", email="none",
group=""):
        from model import Group
        user = model.User(user_name=name, password=passwd,
email_address=email)
        g=Group.select(group)
        g.addUser(user)

but the error in adduser_func:
    g.addUser(user)
AttributeError: 'SelectResults' object has no attribute 'addUser'

addUser seem to work in tg-shell, but not in code. Is there another
method for this? How can i associate a User to an existing Group?

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to