MOSS 2007 - 自定义发送到菜单

发布于 2024-08-16 09:04:47 字数 186 浏览 2 评论 0原文

目前,我们需要向文档库中的“发送到”菜单添加一个自定义菜单项,该菜单项将允许用户创建指向另一个库中当前所选列表项的链接。当用户单击新的“将链接发送到...”菜单项时,系统应提示他们浏览到应添加链接的库。一旦用户选择了目的地,链接以及列表项中的元数据就会神奇地出现在所选目的地库中。再说一次,我们只想要一个链接,而不是文件的副本。这可以吗?代码示例将不胜感激。

We currently have a need to add a custom menu item to the Send To menu within our document libraries that would allow a user to create a link to the currently selected list item within another library. When the user clicks on the new "Send Link to..." menu item, they should be prompted to browse to the library in which the link should be added. Once the user chooses a destination, the link, along with the metadata from the list item, should magically appear in the selected desitnation library. Once again, we only want a link, not a copy of the file. Is this possible to do? Code examples would be much appreciated.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

乙白 2024-08-23 09:04:47

它必须在发送到菜单中吗?它也可以直接在上下文菜单中(比如在底部)吗?如果是这样,您可以创建一个将 CustomAction 部署到站点的功能。如果确实需要位于“发送到”菜单下,则您将必须使用 javascript(因为这就是创建开箱即用的上下文菜单的方式)来“劫持”菜单并插入您自己的项目。

恕我直言,这很少需要,CustomAction 是执行此操作的首选方式。它是最简单且最“可维护”的(它只是一个功能+自定义操作定义,可能还有一些代码,所有这些都使用解决方案进行部署)。

有关 CustomActions 的更多信息此处 .

PS,如果您决定使用 javascript,请不要在 SharePoint 12 Hive 中编辑开箱即用的 sharepoint js 文件,而是向页面添加 ContentEditorWebPart 并在其中插入 Javascript。

PPS 虽然在大多数情况下允许将程序集中的方法分配为 CustomAction 的操作,但不适用于 ListEdit(项目)上下文菜单。

Does it have to be in the send to menu? Can it also be directly in the context menu (say at the bottom)? If so, you can create a feature that deploys a CustomAction to the site. If it really, REALLY needs to be under the "send to" menu, you are going to have to use javascript (since that is how the out of the box context menu is created) to "hijack" the menu and insert your own item.

IMHO this is rarely needed, a CustomAction is the preferred way of doing this. It is the easiest and most "maintainable" (all it is is a feature + customaction definition with maybe some code, all of which are deployed using a solution).

More info on CustomActions here.

P.S. if you do decide to go with javascript, don't go editing the out of the box sharepoint js files in SharePoint's 12 Hive, but add a ContentEditorWebPart to the page and insert your Javascript in there.

P.P.S. While assigning a method from an assembly as the action for a CustomAction is allowed in most cases, it is not for the ListEdit (item) context menu.

情何以堪。 2024-08-23 09:04:47

他们所说的是“Sharepoint 服务器 2010 将开箱即用”,即文档可以保留在创建它们的位置,并且链接到记录中心(名为“就地记录管理,请参阅 http://www.cmswire.com/cms/document-管理/the-scoop-sharepoint-2010-records-management-005948.php)。
MOSS 2007 要求将实际文档复制到记录存储库中才能注册。

What they say is that "Sharepoint server 2010 will have it out of the box", i.e. documents may stay where they were created and links go to the Records center (named "In Place Records Management, see http://www.cmswire.com/cms/document-management/the-scoop-sharepoint-2010-records-management-005948.php).
MOSS 2007 requires the actual document to be copied to the Records repository to be registered.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文