嗨,我需要在基于标志值(真/假(的 jsf 元素中显示工具提示。
元素:
<h:outputLabel value="#{msg['dealsheet.label.nonpromoted']}" />
工具提示文本:">这表示交易的状态">
条件: #{ds.partialLockOutFlag}
当上述标志的值为 true 时,悬停时工具提示消息应在标签上可见。
谁能建议如何实现这一目标?
您可以在 true 时显示消息,否则显示空字符串:
<h:outputLabel value="#{msg['dealsheet.label.nonpromoted']}" title="#{ds.partialLockOutFlag} ? 'This denotes the status of the deal' : '' " />