如何跟踪文件夹权限事件?
这是关于文件夹级别的权限。我们有一个具有中断继承性的文档库。在通过代码添加文件夹、子文件夹时,我们再次编写了打破继承的代码。 现在的需求是,当一个用户/组被添加到子文件夹权限列表中时,我们需要跟踪这个事件。我们使用哪个共享点事件以及在什么级别上使用。请帮忙。
This is about folder level permissions. We have a document library with break inheritance. While adding folders, sub folders through code, again we coded for break inheritance.
Now the requirement is, when a user/group is added to subfolder permission list, we need to track this event. Which sharepoint event do we use and on what level. Please help.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
如果在列表/站点上启用了审核,您可以从审核日志中获取此信息。
MOSS 附带一些基本的审计报告。有关详细信息,请参阅 Office Online 上的此资源。
或者,查看我们的 SharePoint 审核套件。它很便宜,而且正是您所追求的。
我曾研究过这个产品,所以我显然有偏见:-)
You can get this information from the Audit log providing auditing is enabled on the List / Site.
MOSS comes with some basic audit reports. Have a look at this resource on Office Online for more details.
Alternatively, have a look at our SharePoint Audit Suite. It is cheap and does exactly what you are after.
I worked on the product so I am obviously biased :-)
基本上是做不到的。您需要确保设置这些权限的任何用户/进程都是通过您编写的代码来完成的,以便您可以从那里调用自定义代码。
请参阅ListItems 权限更改时的 SharePoint 事件? .
Basically, it can't be done. You need to make sure whatever user/process is setting those permissions is doing it through code written by you, so you can call your custom code from there.
See SharePoint Event when Permissions of ListItems have been changed? .
我已经为我的问题找到了解决方案(尽管有点妥协)。我只想在一个文档库中实现这一目标。我将在这里解释这个过程。
权限页面始终为“user.aspx”,添加新权限页面为“aclinv.aspx”。
我为“aclinv.aspx”实现了一个 httpmodule url 侦听器。因此,当请求此页面时,我会将其转移到我的自定义权限页面。有趣的是,sharepoint 中的 url 是每个操作的关键。它在 url 中将我的文件夹名称作为 id,文档库名称也是一个 id。
自定义权限页面与“aclinv.aspx”完全相同,只是应用程序正在侦听此页面。当在此页面上选择具有适当权限的用户时,应用程序会通过 url 跟踪用户 ID、所选权限、文件夹 ID、文档库 ID 等所有内容,并且流程保持不变。
就这样,工作完成了。有了所有这些值,应用程序就可以对新请求执行任何操作。
非常感谢大家的指导。这真的很有帮助。
附言。如果有更好的方法来做到这一点,我很高兴知道。
苏珊特
I have reached a solution for my problem(bit compromising though). I wanted to achieve this in one document library only. I will explain the process here.
The permissions page is always "user.aspx" and add new permissions page is "aclinv.aspx".
I implemented an httpmodule url listener for "aclinv.aspx". So when this page is requested, I transfer it my custom permissions page. Interestingly, url's in sharepoint are the key to every operation. It had my folder name in url as an id, the document library name also an id.
The custom permissions page is exactly similar to "aclinv.aspx" except the fact that the application is listening for this page. When user is selected with proper permissions on this page, the application tracks the userid, selected permission, folder id, document library id everything through the url and the flow remains the same.
Thats it, job done. With all these values, the application can do whatever it wnats to the new request.
Thanks a lot to all for your guidance. It really helped a lot.
PS. If there is a better way to do this, I would be glad to know.
Sushant