zoukankan      html  css  js  c++  java
  • SharePoint Data View Conditional Formatting based on user permissions (IfHasRights)

    Below are the values for conditional formatting

    example usage : <xsl:if test=”ddwrt:IfHasRights(“REPLACE THIS WITH BELOW VALUE”)”><img alt=”" border=”0″ src=”http://www.cnblogs.com/PublishingImages/btn_AddActionItem.jpg” width=”191″ height=”37″ /></xsl:if>

    ViewListItems – 1

    AddListItems – 2

    EditListItems – 4

    DeleteListItems – 8

    ApproveItems – 16

    OpenItems – 32

    ViewVersions – 64

    DeleteVersions – 128

    CancelCheckout – 256

    PersonalViews – 512

    ManageLists – 2048

    ViewFormPages – 4096

    Open – 65536

    ViewPages – 131072

    AddAndCustomizePages – 262144

    ApplyThemeAndBorder – 524288

    ApplyStyleSheets – 1048576

    ViewUsageData – 2097152

    CreateSSCSite – 4194314

    ManageSubwebs – 8388608

    CreateGroups – 16777216

    ManagePermissions – 33554432

    BrowseDirectories – 67108864

    BrowseUserInfo – 134217728

    AddDelPrivateWebParts – 268435456

    UpdatePersonalWebParts – 536870912

    ManageWeb – 1073741824

    UseRemoteAPIs – 137438953472

    ManageAlerts – 274877906944

    CreateAlerts – 549755813888

    EditMyUserInfo – 1099511627776

    EnumeratePermissions – 4611686018427387904

    FullMask – 9223372036854775807

    To ensure that users only see the edit button if they are the author of the posting, or a site owner we added the following conditional formatting:


    test=”ddwrt:IfHasRights(2048) or contains(@Author,$Userid)”


  • 相关阅读:
    C++11模板类使用心得
    Linux下MakeFile初探
    Leetcode 35 Search Insert Position 二分查找(二分下标)
    Leetcode 4 Median of Two Sorted Arrays 二分查找(二分答案+二分下标)
    数据库分库分表的应用场景及方法分析
    DB主从一致性的几种解决方法
    Redis主从复制和集群配置
    RPC vs RESTful
    Mysql锁详解
    BIO与NIO、AIO的区别
  • 原文地址:https://www.cnblogs.com/bmib/p/2163354.html
Copyright © 2011-2022 走看看