Alfresco:文件夹权限(按角色) [英] Alfresco: Folder permission by role

查看:227
本文介绍了Alfresco:文件夹权限(按角色)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

问题:我们有一个空间模板,用作共享网站文档库的文件夹结构。我们的目标是使某些文件夹对具有自定义角色的特殊用户可见(在sitePermissions.xml中创建)。
通常我们可以使用组来完成,但是我们需要使用角色来完成(例如,当我们邀请外部用户时,我们希望将他分配给内部角色,以便他可以自动看到一些文件夹)。

Problem: we have a space template that we use as a folder structure for share sites document library. Our aim is to make visible some folders to special users that have a custom role (created in sitePermissions.xml). generally we can do that with groups but we need to do that with roles (e.g. when we invite an external user, we wish to assign him to an internal role so he can automatically see some folders).

请帮助我们提供一些线索。

Please help us with some clues.

推荐答案

可能,但您不知道想像安德里亚斯(Andreas)建议的那样去那里。甚至Alfresco自己的(较旧的)网站权限也是一样。 site_manager,site_collaborator等是Alfresco创建的系统组,如果您属于这些组之一,则您将在该站点内获得许可。

It's possible but you don't want to go there like Andreas is suggesting. Even Alfresco's own (older way) of site permissions is the same. The site_manager, site_collaborator etc. are system groups which Alfresco creates and if you're in one of those groups you'll have your permission within the site.

仍然坚持,这是要走的路。
有2个用于获取Documentlibrary的存储库脚本(不包括搜索,文档详细信息等其他方式)

Oke if you still insist, here is the way to go. There are 2 repository webscripts to get the Documentlibrary (not counting other ways like search, document-details, etc.)


  • alfresco\templates\webscripts\org\alfresco\slingshot\documentlibrary-v2\doclist.get

  • alfresco\templates\webscripts\org\alfresco \slingshot\documentlibrary\treenode.get

打开相应的.js文件(覆盖它们)。遍历项目时,获取节点的所有权限集,然后将权限与所需的权限集匹配。

Open the corresponding .js files (override them). When looping through the items get all the permissionset for the node, then match the permission to the one you need. If it's true go through and if it's false don't add it.

然后再次声明这是一项繁重的操作,所以如果您有一个很大的文件夹集合,并且您与100个并发用户一起执行此操作,这些用户将对性能不满意。

Then again I want to state that this is a heavy operation, so if you have a huge folder collection and you're doing this with like 100 concurrent user, the users won't be happy with the performance.

这篇关于Alfresco:文件夹权限(按角色)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆