SharePoint SC "Audit Settings"功能与CSOM的对应
2016-04-21 14:33
513 查看
博客地址:http://blog.csdn.net/FoxDaveSharePoint网站集中有个关于审计的功能:"Site collection audit settings",可以用CSOM通过Site的一些属性去设置它。
Audit Log Trimming部分:
Automatically trim the audit log for this site?
对应的属性为:site.TrimAuditLog
布尔类型,通过true/false的设置进行更新。
Optionally, specify the number of days of audit log data to retain:
对应的属性为:site.AuditLogTrimmingRetention
整型,通过数字来设置审计日志保留的天数。
If you'd like to keep audit data for longer than this, please specify a document library where we can store audit reports before trimming occurs:
这个目前比较麻烦,没有暴露了出属性来,可以通过web的_auditlogreportstoragelocation属性获取和设置,但是幸运的是只能选择Root Web上的某个文档库的位置:
site.RootWeb.AllProperties["_auditlogreportstoragelocation"]Specify the events to audit:
对应的属性为:site.Audit.AuditFlags
枚举类型,多个选项用|连接,例如:
audit.AuditFlags = AuditMaskType.Update | AuditMaskType.Copy | AuditMaskType.Move | AuditMaskType.Search;以上就是审计设置相关的CSOM属性,可以用来方便地获取与设置网站集的审计设置。
Audit Log Trimming部分:
Automatically trim the audit log for this site?
对应的属性为:site.TrimAuditLog
布尔类型,通过true/false的设置进行更新。
Optionally, specify the number of days of audit log data to retain:
对应的属性为:site.AuditLogTrimmingRetention
整型,通过数字来设置审计日志保留的天数。
If you'd like to keep audit data for longer than this, please specify a document library where we can store audit reports before trimming occurs:
这个目前比较麻烦,没有暴露了出属性来,可以通过web的_auditlogreportstoragelocation属性获取和设置,但是幸运的是只能选择Root Web上的某个文档库的位置:
site.RootWeb.AllProperties["_auditlogreportstoragelocation"]Specify the events to audit:
对应的属性为:site.Audit.AuditFlags
枚举类型,多个选项用|连接,例如:
audit.AuditFlags = AuditMaskType.Update | AuditMaskType.Copy | AuditMaskType.Move | AuditMaskType.Search;以上就是审计设置相关的CSOM属性,可以用来方便地获取与设置网站集的审计设置。
相关文章推荐
- nodejs development
- Technical Information Release For Bridger 1.0
- About Us
- Office 365 Code Snippets for Windows
- Office 365 Service Communications API operations--Get Services
- Office 365 Service Communications API operations--Get Current Status
- Office 365 Service Communications API operations--Get Historical Status
- Office 365 Service Communications API operations--Get Messages
- Office 365 Service Communications API reference
- Coder开发效率之草论
- Sharepoint应用EWSManagedAPI操作Exchange邮箱
- toast的几种用法
- sharepoint视图权限控制器二次开发
- SharePoint 2013 中的服务
- 通过Feature部署Sharepoint 2013的EventReceiver
- 错误:该表单无法显示,可能是由于 Microsoft SharePoint Server State Service 配置不当。有关详细信息,请与服务器管理员联系
- SharePoint 中修改域用户密码的WebPart文件配置
- Your first video app: show a video preview on screen
- 源码编译MySQL5.6.24
- php学习笔记