0
votes

trying alfresco share 4.2c.

say i created two sites; siteA and siteB. (siteA users and siteB users are in the same repository of users.) i am trying to figure out how to prevent siteB users access to siteA workflows.

in creating a workflow for siteA, how can i prevent siteB users from being accidentally assigned to a siteA-workflow task? that is, i need to ensure that the selected task assignee is a user from siteA only. OR it would be better if only siteA users are shown in the selection list.

any leads or suggestions to accomplish that will be most welcome.

thanks,
popoyorc

edit: as a start, basically what we want is something like this:

there are several allSites-workflows that will be available to all members regardless of site membership.

we can impose prefixing of workflow names with the site name.

for siteA members, they should be able to view and select allSites-workflows plus siteA-workflows.
siteB members can only view and select allSites-workflows plus siteB-workflows.

if that can be done, can you point us to the location of the codes/files that we can tweak or extend to achieve the above? we want to encode some 'filtering' on the workflow names to list for selection, but we don't know how and where to encode these.

then maybe we can next progress to Tahir's (thanks) suggestions by filtering on group names that are also sitename prefixed.

many thanks.

1

1 Answers

1
votes

This maybe a difficult one for someone with limited Alfresco knowledge, so hopefully you'll understand it.

  1. You'll need to create a repository webscript which takes as input a site and uses siteService methods to get the members and groups. You can peak at the siteMembers Share page which probably uses something similar to show the members and groups. And you'll probably will need to make it searchable :).
  2. Change the current custom control which uses the default picker to select users/groups. Probably you'll only need to change the repository webscript url so it goes to the right new webscript. If you don't want to make any more changes, be sure to present the output in the exact same way.
  3. You can start a workflow from you personal dashboard of from the my-workflow pages, so there is not always a site. And even if you're starting from a site big changes the site doesn't get passed to the start-workflow page. So you'll need to get the destination nodeRef (the node you're starting the workflow on) send it as param to your repository webscript and let it determine which site it is in.

First change the custom control which selects the assignee. This control goes to a repository webscript which shows/searches all the users/groups.