It sounds like your entities should have a UserGroup associated with them. When someone joines a department, you could then add them to the appropriate user group for entities if the entity was a member of that department entity group.
On Fri, Jan 21, 2011 at 8:53 AM, <brunomlo...@gmail.com> wrote: > The scenario I'm looking at is when I save an entity and I need to remove or > add permissions to the entity, based on the users associated with it and the > entity status. > > This may involve permissions given to a specific user or to a group of > users. > > Example: a draft can only be viewed by the author. A private entity can be > viewed by the author, a list of other users and the department manager for > the entity. The list of users can change, and so can the department. > The department is represented by a UserGroup with only the manager. I'm also > thinking that a department would be an EntityGroup to which the entity would > be attached and detached. > > The simplest way I can think of is to "nuke" all permissions specific to the > entity, and just rebuild them on save. > Another option I see is to have an UserGroup for each entity with the users > with permission to see the entity, and sync the list on the entity with the > UserGroup list. > > What is the correct approach to handle changing permissions on entities? > > -- > You received this message because you are subscribed to the Google Groups > "Rhino Tools Dev" group. > To post to this group, send email to rhino-tools-dev@googlegroups.com. > To unsubscribe from this group, send email to > rhino-tools-dev+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/rhino-tools-dev?hl=en. > -- You received this message because you are subscribed to the Google Groups "Rhino Tools Dev" group. To post to this group, send email to rhino-tools-dev@googlegroups.com. To unsubscribe from this group, send email to rhino-tools-dev+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rhino-tools-dev?hl=en.