Sadece Site collection admin'ler görmesi için PermissionsString="ManageWeb" olarak yaptım.
Son hali şu şekilde:
Site Actions için SharePoint:SiteActions kontrolünü kalın olarak işaretlediğim SharePoint:SPSecurityTrimmedControl kontrolü içinde aldım.
<SharePoint:SPSecurityTrimmedControl ID="secForSiteActions" runat="server" PermissionsString="ManageWeb">
<SharePoint:SiteActions runat="server" accesskey="<%$Resources:wss,tb_SiteActions_AK%>" id="SiteActionsMenuMain"
PrefixHtml=""
SuffixHtml=""
MenuNotVisibleHtml="&nbsp;"
>
<CustomTemplate>
<SharePoint:FeatureMenuTemplate runat="server"
FeatureScope="Site"
Location="Microsoft.SharePoint.StandardMenu"
GroupId="SiteActions"
UseShortId="true"
>
<SharePoint:MenuItemTemplate runat="server" id="MenuItem_EditPage"
Text="<%$Resources:wss,siteactions_editpage%>"
Description="<%$Resources:wss,siteactions_editpagedescriptionv4%>"
ImageUrl="/_layouts/images/ActionsEditPage.png"
MenuGroupId="100"
Sequence="110"
ClientOnClickNavigateUrl="javascript:ChangeLayoutMode(false);"
/>
<SharePoint:MenuItemTemplate runat="server" id="MenuItem_TakeOffline"
Text="<%$Resources:wss,siteactions_takeoffline%>"
Description="<%$Resources:wss,siteactions_takeofflinedescription%>"
ImageUrl="/_layouts/images/connecttospworkspace32.png"
MenuGroupId="100"
Sequence="120"
/>
<SharePoint:MenuItemTemplate runat="server" id="MenuItem_CreatePage"
Text="<%$Resources:wss,siteactions_createpage%>"
Description="<%$Resources:wss,siteactions_createpagedesc%>"
ImageUrl="/_layouts/images/NewContentPageHH.png"
MenuGroupId="200"
Sequence="210"
UseShortId="true"
ClientOnClickScriptContainingPrefixedUrl="if (LaunchCreateHandler('Page')) { OpenCreateWebPageDialog('~site/_layouts/createwebpage.aspx') }"
PermissionsString="AddListItems, EditListItems"
PermissionMode="All" />
<SharePoint:MenuItemTemplate runat="server" id="MenuItem_CreateDocLib"
Text="<%$Resources:wss,siteactions_createdoclib%>"
Description="<%$Resources:wss,siteactions_createdoclibdesc%>"
ImageUrl="/_layouts/images/NewDocLibHH.png"
MenuGroupId="200"
Sequence="220"
UseShortId="true"
ClientOnClickScriptContainingPrefixedUrl="if (LaunchCreateHandler('DocLib')) { GoToPage('~site/_layouts/new.aspx?FeatureId={00bfea71-e717-4e80-aa17-d0c71b360101}&ListTemplate=101') }"
PermissionsString="ManageLists"
PermissionMode="Any"
VisibilityFeatureId="00BFEA71-E717-4E80-AA17-D0C71B360101" />
<SharePoint:MenuItemTemplate runat="server" id="MenuItem_CreateSite"
Text="<%$Resources:wss,siteactions_createsite%>"
Description="<%$Resources:wss,siteactions_createsitedesc%>"
ImageUrl="/_layouts/images/newweb32.png"
MenuGroupId="200"
Sequence="230"
UseShortId="true"
ClientOnClickScriptContainingPrefixedUrl="if (LaunchCreateHandler('Site')) { STSNavigate('~site/_layouts/newsbweb.aspx') }"
PermissionsString="ManageSubwebs,ViewFormPages"
PermissionMode="All" />
<SharePoint:MenuItemTemplate runat="server" id="MenuItem_Create"
Text="<%$Resources:wss,siteactions_create%>"
Description="<%$Resources:wss,siteactions_createdesc%>"
MenuGroupId="200"
Sequence="240"
UseShortId="true"
ClientOnClickScriptContainingPrefixedUrl="if (LaunchCreateHandler('All')) { STSNavigate('~site/_layouts/create.aspx') }"
PermissionsString="ManageLists, ManageSubwebs"
PermissionMode="Any" />
<SharePoint:MenuItemTemplate runat="server" id="MenuItem_ViewAllSiteContents"
Text="<%$Resources:wss,quiklnch_allcontent%>"
Description="<%$Resources:wss,siteactions_allcontentdescription%>"
ImageUrl="/_layouts/images/allcontent32.png"
MenuGroupId="300"
Sequence="302"
UseShortId="true"
ClientOnClickNavigateUrl="~site/_layouts/viewlsts.aspx"
PermissionsString="ViewFormPages"
PermissionMode="Any" />
<SharePoint:MenuItemTemplate runat="server" id="MenuItem_EditSite"
Text="<%$Resources:wss,siteactions_editsite%>"
Description="<%$Resources:wss,siteactions_editsitedescription%>"
ImageUrl="/_layouts/images/SharePointDesigner32.png"
MenuGroupId="300"
Sequence="304"
UseShortId="true"
ClientOnClickScriptContainingPrefixedUrl="EditInSPD('~site/',true);"
PermissionsString="AddAndCustomizePages"
PermissionMode="Any"
/>
<SharePoint:MenuItemTemplate runat="server" id="MenuItem_SitePermissions"
Text="<%$Resources:wss,people_sitepermissions%>"
Description="<%$Resources:wss,siteactions_sitepermissiondescriptionv4%>"
ImageUrl="/_layouts/images/Permissions32.png"
MenuGroupId="300"
Sequence="310"
UseShortId="true"
ClientOnClickNavigateUrl="~site/_layouts/user.aspx"
PermissionsString="EnumeratePermissions"
PermissionMode="Any" />
<SharePoint:MenuItemTemplate runat="server" id="MenuItem_Settings"
Text="<%$Resources:wss,settings_pagetitle%>"
Description="<%$Resources:wss,siteactions_sitesettingsdescriptionv4%>"
ImageUrl="/_layouts/images/settingsIcon.png"
MenuGroupId="300"
Sequence="320"
UseShortId="true"
ClientOnClickNavigateUrl="~site/_layouts/settings.aspx"
PermissionsString="EnumeratePermissions,ManageWeb,ManageSubwebs,AddAndCustomizePages,ApplyThemeAndBorder,ManageAlerts,ManageLists,ViewUsageData"
PermissionMode="Any" />
<SharePoint:MenuItemTemplate runat="server" id="MenuItem_CommitNewUI"
Text="<%$Resources:wss,siteactions_commitnewui%>"
Description="<%$Resources:wss,siteactions_commitnewuidescription%>"
ImageUrl="/_layouts/images/visualupgradehh.png"
MenuGroupId="300"
Sequence="330"
UseShortId="true"
ClientOnClickScriptContainingPrefixedUrl="GoToPage('~site/_layouts/prjsetng.aspx')"
PermissionsString="ManageWeb"
PermissionMode="Any"
ShowOnlyIfUIVersionConfigurationEnabled="true" />
</SharePoint:FeatureMenuTemplate>
</CustomTemplate>
</SharePoint:SiteActions>
</SharePoint:SPSecurityTrimmedControl>
Geri Dönüşüm ve Tüm İçerikler linkini kalın ile işaretlediğim kontrol içine aldım.
<SharePoint:UIVersionedContent UIVersion="4" runat="server" id="PlaceHolderQuickLaunchBottomV4">
<ContentTemplate>
<ul class="s4-specialNavLinkList">
<li>
<SharePoint:SPSecurityTrimmedControl runat="server" ID="secForRecycleBinLink" PermissionsString="ManageWeb">
<SharePoint:ClusteredSPLinkButton
runat="server"
NavigateUrl="~site/_layouts/recyclebin.aspx"
ImageClass="s4-specialNavIcon"
ImageUrl="/_layouts/images/fgimg.png"
ImageWidth=16
ImageHeight=16
OffsetX=0
OffsetY=428
id="idNavLinkRecycleBin"
Text="<%$Resources:wss,StsDefault_RecycleBin%>"
CssClass="s4-rcycl"
PermissionsString="DeleteListItems" />
</SharePoint:SPSecurityTrimmedControl>
</li>
<li>
<SharePoint:SPSecurityTrimmedControl runat="server" ID="secForAllContentLink" PermissionsString="ManageWeb">
<SharePoint:ClusteredSPLinkButton
id="idNavLinkViewAllV4"
runat="server"
PermissionsString="ViewFormPages"
NavigateUrl="~site/_layouts/viewlsts.aspx"
ImageClass="s4-specialNavIcon"
ImageUrl="/_layouts/images/fgimg.png"
ImageWidth=16
ImageHeight=16
OffsetX=0
OffsetY=0
Text="<%$Resources:wss,quiklnch_allcontent_short%>"
accesskey="<%$Resources:wss,quiklnch_allcontent_AK%>" />
</SharePoint:SPSecurityTrimmedControl>
</li>
</ul>
</ContentTemplate>
</SharePoint:UIVersionedContent>
İşlemleri tamamladıktan sonra bu master page dosyasını önce CheckIn (gelen menüde publish major'u seçtim) sonra Approve yapmalısınız. Approve yapmanız için bir popupda soracaktır, OK diyerek ilgili onaylama listesi gelecek (bu listede bu sayfa Pending durumunda olacak). İlgili Item'ın context menüsünde Approve/Reject seçerek, Approve radio butonu seçmelisiniz. Yaptığımız değişiklikler tüm siteye yansıyacaktır.
Kaynak:
http://blog-sharepoint.blogspot.com/2011/10/apply-permissions-to-custom-ui-links.html
http://www.sharepointkings.com/2008/11/how-to-remove-site-actions-and-view-all.html
http://www.learningsharepoint.com/2010/07/06/hiding-view-all-site-content-and-recycle-bin-link-from-quick-launch/
Hiç yorum yok:
Yorum Gönder