是否可以删除“上传MM组件"?SDL Tridion 2011 功能区中的按钮 [英] Is it possible to remove the "Upload MM Component" button from the SDL Tridion 2011 Ribbon

查看:25
本文介绍了是否可以删除“上传MM组件"?SDL Tridion 2011 功能区中的按钮的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这个按钮给我的客户带来了很多问题,因为它总是使用预定义的架构.我找不到使用我的编辑器配置删除此按钮的方法.我已经使用其他按钮完成了此操作,但是这些按钮是在某种子组中实现的.

This button causes a lot of problems for my client, as it always uses a predefined Schema. I can't find a way to remove this button with my Editor config. I have done this with other buttons, but these buttons are implemented in some sort of sub-group.

在我的个人沙箱机器上,我尝试删除 ../WebUI/Editors/CME/Controls/Toolbars/Tabs/CreateRibbonPage.ascx 文件的摘录中注释掉的控件,如下所示:

On my personal sandbox machine, I tried removing the commented out control in the extract of the ../WebUI/Editors/CME/Controls/Toolbars/Tabs/CreateRibbonPage.ascx file shown below:

<c:RibbonSplitButton runat="server" CommandName="NewComponent" 
   Title="<%$ Resources: Tridion.Web.UI.Strings, NewComponent %>" 
   Label="<%$ Resources: Tridion.Web.UI.Strings, NewComponent %>"
   ID="NewComponentBtn1">
  <c:RibbonContextMenuItem runat="server" ID="NewComponentCMI2" 
     Command="NewComponent" 
     Title="<%$ Resources: Tridion.Web.UI.Strings, NewComponent %>" 
     Label="<%$ Resources: Tridion.Web.UI.Strings, NewComponent %>" />
  <c:RibbonContextMenuItem runat="server" ID="NewMultimediaComponentCMI2" 
     Command="NewMultimediaComponent"  
     Title="<%$ Resources: Tridion.Web.UI.Strings, NewMultimediaComponent %>" 
     Label="<%$ Resources: Tridion.Web.UI.Strings, NewMultimediaComponent %>" />
  <!--
  <c:RibbonUploadContextMenuItem runat="server" 
     ID="NewBasicMultimediaComponentCMI2" Command="NewBasicMultimediaComponent"  
     Title="<%$ Resources: Tridion.Web.UI.Strings, NewBasicMultimediaComponent %>"
     Label="<%$ Resources: Tridion.Web.UI.Strings, NewBasicMultimediaComponent %>" />
  -->
</c:RibbonSplitButton>

这似乎达到了预期的结果,但我想如果我在客户环境中这样做,这可能会使我们的支持协议无效.这是否可以以受支持的方式进行,或者我是否必须像这样破解 UI 文件才能实现我的目标?

This seems to have the desired result, but I imagine that this will probably invalidate our support agreement if I did this in a customer environment. Is this possible to do in a supported way, or do I have to hack the UI files like this to achieve my goal?

推荐答案

解决方案之一是为 NewBasicMultimediaComponent 命令创建扩展,它扩展了 isAvailableisEnabled 方法并为它们返回 false.在这种情况下,上传 MM 组件"仍将作为新建组件"按钮的选项出现,但它将被禁用.

One of the solutions is to create extension for the NewBasicMultimediaComponent command, which extends isAvailable and isEnabled methods and returns false for them. In this case "Upload MM Component" still will be present as an option for "New Component" button, but it will be disabled.

这篇关于是否可以删除“上传MM组件"?SDL Tridion 2011 功能区中的按钮的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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