Hi,
I have Workflow A assigned to CT1(Content type 1) as default WF. I have another Workflow B assigned to CT2(Content type 2) as default WF.
I have a situation where I need the roles/users assigned to WFB has to create CT1 items.
I tried to add WFB as “allowed WF” to CT1. But it doesn’t work.
Any thoughts?
When an item is created by default it requires one and only one workflow to be selected for that item. How it does this is by taking the list of allowed workflows and filtering these by which are valid for the community the user is logged in as. So if workflow a is in community a and workflow b is in community b and both workflows are added as allowed for content type 1 then the appropiate wf will be selected for the item.
The other way of doing what you want is to unhide the hidden sys_workflow field. This is set as a dropdown but is normally hidden so if only one option is available, that is selected. If this is unhidden and there is more than one available workflow, the user will have to select the appropriate one. It should be set so it is hidden if a value is already set on the item as you would not want the workflow changed in this way once it is set.
Of course if you just want the other set of users to be able to create the items. You could just add the wf2 users as assignees of the draft state of wf2. The content type 1 would always be in wf1 in this case.
That means there is no way other than adding the users/roles to the WF B (with the exemption of sys_workflow field approach) right? which wouldn’t be very appropriate, b’caz there is no point in having multiple Wf’s then.
With that said…
I have another scenario…
CT1,CT2… are assigned to WF A. I have role R1 that should be allowed to enter/modify only for CT2 items … How can i restrict R1 users not to have access to CT1?
Paddy,
Percussion’s out of the box functionality expects that one workflow will be “available” to select at the time of content creation as a function of the allowed workflows and the logged in users community role(s) and workflow role(s), as sbolton described. You can “unhide” the the sys_workflow field and allow the user to select as well. Anything beyond that, such as the second scenario you described, will require writing an extension (which requires one to be a Java developer) to select the correct workflow based on your business rules. This has been an issue for us as well, as it essentitally prevents you from easily sharing content types across user bases with different workflows.