我正在尝试ajax更新有条件渲染的组件.
<h:form>
...
<h:commandButton value="Login" action="#{login.submit}">
<f:ajax execute="@form" render=":text" />
</h:commandButton>
</h:form>
<h:outputText id="text" value="You're logged in!" rendered="#{not empty user}" />
Run Code Online (Sandbox Code Playgroud)
但是,这不起作用.我可以保证这#{user}实际上是可用的.这是怎么造成的,我该如何解决?
jsf rendered-attribute jsf-2 conditional-rendering ajax-update