How to restrict to empty trashcan

cancel
Showing results for 
Search instead for 
Did you mean: 
lfedorikova
Member II

How to restrict to empty trashcan

Jump to solution

I would like to restrict emptying of trashcan by ordinary users. Permission to empty trashcan should have only users with admin role.

Is there any way how to solve this issue? For example to implement Java method used as evaluator before button displaying? Or any other sophisticated way, solution or implementation, how to secure this resctriction?

Thanks Smiley Happy

1 Solution

Accepted Solutions
angelborroy
Alfresco Employee

Re: How to restrict to empty trashcan

Jump to solution

You can add your restrictions to Share UI and to Repository service.

In order to hide the Share UI button for non Admin users, you can extend Alfresco.ConsoleTrashcan YUI object:

https://github.com/Alfresco/share/blob/alfresco-share-parent-6.2.0/share/src/main/webapp/components/...

Regarding Repository service, you can create a new NodeServicePolicies.onDeleteNode behaviour listening to sys:archived nodes.

Hyland Developer Evangelist

View solution in original post

2 Replies
angelborroy
Alfresco Employee

Re: How to restrict to empty trashcan

Jump to solution

You can add your restrictions to Share UI and to Repository service.

In order to hide the Share UI button for non Admin users, you can extend Alfresco.ConsoleTrashcan YUI object:

https://github.com/Alfresco/share/blob/alfresco-share-parent-6.2.0/share/src/main/webapp/components/...

Regarding Repository service, you can create a new NodeServicePolicies.onDeleteNode behaviour listening to sys:archived nodes.

Hyland Developer Evangelist
bip1989
Established Member

Re: How to restrict to empty trashcan

Jump to solution

I also have this kind of requirement, thanks for sharing the link.