在 Oracle Apex 的 IR 中禁用 Link

Disable a Link in IR in Oracle Apex

我有一个问题。我的交互式报告 Table 中有三列。第一列是 MID,它是隐藏的。其他列是 MNAME 和 Revenue。 MID 是 MNAME 的 ID。当ID不为null时,当然是我在填它的MNAME。当 ID 为 null 时,它在我的查询中被命名为 'Others'.

我已经为应用程序中其他页面的 MNAME 创建了一个 link。当 MID 为空时,我想禁用 link。或者换句话说,当 MNAME 为 'Others' 时,则必须禁用 Link。我怎样才能做到这一点 ? 非常感谢您的帮助和评论。

在 Apex 本身中,您不能这样做,因为“Link”属性 没有“条件”。因此,在交互式报表的查询中自己创建一个 link。

例如:

select mid, 
       mname,
       revenue,
       --
       case when mid is null then null
            else '<a href="https://www.google.com">Click here</a>'
       end as link
from your_table

link 列的 属性 面板中,将 转义特殊字符 设置为“否”。 运行 页面; link 应该只对 MID 列的值不是 NULL.

的行可见

如果您要导航到应用程序中的另一个页面,

then '<a href="f?p=&APP_ID.:14:&SESSION.">Click here</a>'

如果您想将值传递到另一个页面:

then '<a href="f?p=&APP_ID.:14:&SESSION.::NO::P14_MNAME,P14_MID:P1_MNAME,P1_MID">Click here</a>'
                                              --------- ------- ======== ======
                                              to P14 page       pass items from P1 page