JoshBaltzell
JoshBaltzell

Reputation: 1494

Only allowing Sitecore users to see their own items in Workflow

Is there a way to allow users to see workflow, but only allow them to see their own items within the workflow?

This seems like a problem that would be common. You have a large number of content creators and you only would want them to see how their content is moving in workflow, not the content created by others.

Possible (approximate and messy) solution: The only possibility I could think of would be to turn off rights inheritance so that I could explicitly deny viewing rights to workflow. Then with a custom action in workflow I could explicitly turn on view rights to each item a user submits.

Am I on the right track? I hope not. ;)

Question Clarification: I want approvers to see everything, but I want authors to open workflow and only see their own items, not dozens of items from other authors.

Upvotes: 0

Views: 792

Answers (2)

Marko
Marko

Reputation: 433

Attacking this from another angle, given you want visibility to the authors on if their items have been approved or not, instead of giving them access to the workbox, why not add a customised email action to the approved status (or the approve command) so that the authors receive an email when their item has been approved. You could also customise the email so that it includes a link to the approved item or includes details of the item so that the author can identify the individual item if they have authored multiple items.

There is a sample email action in the Sitecore.Workflows.Simple.EmailAction class in the Sitecore.Kernel assembly that you can use as a base to your customisations.

If you want to make sure that all items are being approved within a certain timeframe, you could also use the ASR shared source module to generate reports on items that have not been approved within a certain timeframe and have it automatically email this report on a regular basis.

Upvotes: 2

dmgdotnet
dmgdotnet

Reputation: 362

This is not the default behaviour as the common use of workflow is for an approval process. In that case the approval team would log in and see the items waiting for approval from the authoring team, if they could only see the items they created then they wouldn't see anything at all.

One way I can think of doing this would be to override the codebeside for the workbox application. Take a look at this file Website\sitecore\shell\Applications\Workbox\Workbox.xml and it's codebeside class Sitecore.Shell.Applications.Workbox.WorkboxForm. If you put your own class in here you could probably add all the logic you need to the 'GetItems' method.

Upvotes: 3

Related Questions