Mike Metcalfe wrote:
[..]
> The problems:
> When I try create a subscription instance in the member profile (with
> at_rename_after_creation = True) I get:
> "The currently logged-in user does not have the <b>Copy or Move</b>
> permission respective to the object". If I give owner this permission in
> the member workflow via the zmi, it works. So I thought I could simply
> add 'Copy or Move' to the private state in my setup handlers like this:
Many times this is a side effect of using 'portal_factory'
as objects are copied from the factory to their final target location.
Since you are dealing with custom types that are only created
in one specific context you might get away without the factory.
You can configure in ZMI -> portal_factory -> factory types tab
which types should "go through the factory" - and which not.
Get back if this doesn't do the trick.
Good luck,
Raphael
>
> pvt = wf.states.get('private')
> perms = pvt.rolesOfPermission(permission='Copy or Move')
> reg_roles = []
> for perm in perms:
> if perm['selected'] == 'SELECTED':
> reg_roles.append(perm['name'])
> if 'Owner' not in reg_roles:
> reg_roles.append('Owner')
> pvt.manage_permission('Copy or Move', roles=reg_roles, acquire=0)
>
> But that doesn't change the workflow:
>
> I also tried to change the permission in
> an IObjectInitializedEvent event handler on member but that didn't work
> either probably because the owner doesn't have Change Permissions
> permission.
>
> I've been sitting with this all day (aaarg) so any pointers will be much
> appreciated.
>
> Thanx,
> Mike
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Product-Developers mailing list
> [email protected]
> http://lists.plone.org/mailman/listinfo/product-developers
_______________________________________________
Product-Developers mailing list
[email protected]
http://lists.plone.org/mailman/listinfo/product-developers