初始位置禁用操作執行:如何在Ajax請求
我們正在使用煤層RichFaces的一起。
<page>
<action execute="#{actionBean.doBefore}"/>
<navigation from-action="#{actionBean.doAfter}">
<redirect view-id="/view/component/test.xhtml" />
</navigation>
</page>
問題
即使執行該操作:
我們得到了以下頁面配置與動作(稱爲actionBean.doBefore),應一次在頁面加載執行當我們驗證每場阿賈克斯:
<h:inputText value="#{formBean.price}" id="price" required="true">
<a4j:support event="onblur" reRender="price" ajaxSingle="true" bypassUpdates="true" />
</h:inputText>
,或者使用意見箱(甚至當你鍵入):
<rich:suggestionbox id="suggestionBoxId" for="city" suggestionAction="#{suggest.autocomplete}" var="result" minChars="3" nothingLabel="No capitals found" ajaxSingle="true" bypassUpdates="true" selfRendered="true" >
<h:column>
<h:outputText value="#{result.cityName}" />
</h:column>
</rich:suggestionbox>
在此先感謝 拉菲