長弘科技 Acumatica 部落格

在Grid中的Selector欄位友善地顯示描述而不是數值

在許多情況下,希望在 Grid 中的 Selector 欄位友善地顯示的描述而不是數值會更讓使用者更清楚地、快速地知道該欄位值真正的意義。 為此,首先在 DAC 中該欄位為相應的Selector attribute 裡添加 DescriptionField 定義所對應的欄位,然後將 SelectorMode 添加到 Selector 定義中或者將 DisplayMode 屬性添加到 aspx。

以下在aspx調整範例:

  • 範例欄位資訊的來源
Graphical user interface, text, application, email

Description automatically generated
  • 在修改DisplayMode屬性前,該欄位的顯示如下

<px:PXGridColumn DataField=”InvetnoryID” TextAlign=”Left” Width=”100px” CommitChanges=”True” />

Graphical user interface, text, application, chat or text message

Description automatically generated
  • 修改 DisplayMode=”Text” 後,會顯示 DescriptionField 值而不是數值

<px:PXGridColumn DataField=”InvetnoryID” DisplayMode=”Text” TextAlign=”Left” Width=”100px” CommitChanges=”True” />

Graphical user interface, text, application

Description automatically generated
  • 將該屬性改成DisplayMode=”Hint” 後,會顯示數值+DescriptionField 值,中間用” – “區隔。

<px:PXGridColumn DataField=”InvetnoryID” DisplayMode=”Hint” TextAlign=”Left” Width=”100px” CommitChanges=”True” />

Graphical user interface, text, application

Description automatically generated

分享文章

Share on facebook
Facebook
Share on linkedin
LinkedIn
Share on google
Google+
Share on twitter
Twitter

相關文章

Copyright © 2021 長弘科技有限公司. All rights reserved