27 Mar
2005
27 Mar
'05
9:14 p.m.
On Mar 27, 2005, at 22:57, Malthe Borch wrote:
Hello list, ---
I'm trying to use the MembershipTool to append a role to one of my users, using the setLocalRoles API-function. How does this function work?
I want to upgrade a user from plain 'Member' to a new role, in a form script.
Are you confusing global roles as stored on a user/member with local roles, as stored on an object in the ZODB? The API document isn't too confusing, I think: def setLocalRoles(obj, member_ids, member_role, reindex=1): """ Add local roles on an item. Permission -- Always available """ You pass in the object (folder, content object, etc) you want to set local roles on, a sequence of member IDs, and the role name. jens