更改 SharePoint 中 BDC 操作的排序顺序

发布于 2024-08-09 13:07:02 字数 633 浏览 1 评论 0 原文

我们在 SharePoint 的 BDC(业务数据目录)定义中定义了许多操作,并且需要更改它们在 UI 中显示的顺序。

在 Action 定义中,有一个 Position 字段,我们正在指定该字段,但是,UI 希望按字母顺序显示所有内容,这不是我们想要的。

BDC 定义的位置部分的示例如下所示。

您知道如何才能成功实现这一目标吗?

<Action 
  Position="10" 
  IsOpenedInNewWindow="true" 
  Url="http://www.google.co.uk/search?q=%22{0}%22"
  ImageUrl="/_layouts/1033/images/TAH/Google.gif" 
  Name="Google for Assured Name">
    <ActionParameters>
        <ActionParameter Index="0" Name="assured_name" />
    </ActionParameters>
</Action>

(PS,我确实考虑过将其放在超级用户上,但是那里没有 BDC,并且这里有许多 BDC 相关问题,所以这里是......;))

We have a number of Actions defined in a BDC (Business Data Catalog) definition in SharePoint, and need to change the order they are displayed in the UI.

Within the Action defintion, there is a Position field, which we are specifying, however, the UI wants to display everything in Alphabetical order, which isn't what we are after.

An example of the Position section of the BDC Definition is shown below.

Do you know how this could be achieved successfully ?

<Action 
  Position="10" 
  IsOpenedInNewWindow="true" 
  Url="http://www.google.co.uk/search?q=%22{0}%22"
  ImageUrl="/_layouts/1033/images/TAH/Google.gif" 
  Name="Google for Assured Name">
    <ActionParameters>
        <ActionParameter Index="0" Name="assured_name" />
    </ActionParameters>
</Action>

(PS I did consider putting this on SuperUser, but there is no BDC there, and there are a number of BDC related questions on here, so here it is... ;) )

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

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

发布评论

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

评论(2

野稚 2024-08-16 13:07:02

您可以通过操作的命名来完成,例如:

  • 01 这是第一个操作
  • 02 这是第二个操作

有点黑客,但它应该可以工作。

You could do through the naming of your actions, for example:

  • 01 This is the first action
  • 02 This is the second action

A bit of a hack, but it should work.

一片旧的回忆 2024-08-16 13:07:02

除了验证其是否存在之外,没有关于 Position 属性的 MSDN 文档(请参阅 操作文档),但假设它应该满足您的要求似乎是合理的。

我怀疑缺乏文档是由于该功能没有完全实现。

可能的工作方法是在Name属性中添加前导空格。如果 BDC 没有自动删除这些空格,您可以使用它来使字母顺序执行您所需要的操作(您拥有的前导空格越多,操作将显示在列表的越靠下的位置)。当呈现为 HTML 时,空格可能会被去除。

There is no MSDN documentation for the Position attribute other than verifying its existence (see Action documentation) but it seems reasonable to assume that it should do what you require.

I suspect that the lack of documentation is due to this feature not being fully implemented.

Something that may work is to add leading spaces in the Name attribute. If BDC does not strip these spaces automatically you could use it to cause the alphabetical ordering to do what you require (the more leading spaces you have, the further down the list the action will appear). When rendered as HTML the spaces will likely be stripped.

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