我似乎有一個問題,我有一個豐富的:popupPanel上的a4j:commandLink,但操作沒有觸發。 XHTML的如下所示:Richfaces 4 a4j:沒有觸發豐富的commandLink操作:popupPanel
<rich:popupPanel id="rate-panel" modal="true" height="444" width="780" top="60" show="false" onmaskclick="#{rich:component('rate-panel')}.hide()" styleClass="cs-modal">
/**Some html here**/
<a4j:commandLink immediate="false" action="#{venueScore.up}" render="rate-panel" styleClass="rate love">
<span>Love it</span>
</a4j:commandLink>
/**Some more html here**/
</rich:popupPanel>
和管理bean如下所示:
@Named("venueScore")
@ViewScoped
public class VenueScoreManager extends BaseManager implements Serializable {
public void up() {
System.out.println("TEST");
//Do something
}
}
我所做的託管bean @ViewScoped。
我也曾嘗試在commandLink周圍添加一個<h:form>
,但是,這比沒有它的情況更少。我其實認爲這是因爲commandLink在<h:form>
之內,其中打開popupPanel的鏈接位於其中。
無論如何,有人可以請我指出爲什麼行動不火嗎?
你無法相信我花了多少時間試圖找到答案!你是如何達到這個解決方案的? –
@ AmrH.AbdelMajeed - 我可能花的時間和你一樣多。嘗試和錯誤到底我認爲解決了它;) –
Omg謝謝! :-D – Gatekeeper