0
p:commandLink
s带有ID cl1
和cl2
不会触发动作。 Tomcat控制台上没有任何东西,Firebug控制台上没有任何东西。p:commandLink不会触发动作
在这种情况下,我应该在哪里寻找问题,我认为我完全绝望,没有任何错误或例外,在两个控制台。
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:c="http://java.sun.com/jsp/jstl/core"
xmlns:o="http://openfaces.org/"
xmlns:p="http://primefaces.org/ui">
<h:form>
<ui:repeat var="sharing" value="#{sharingController.myList}">
<ui:repeat var="sharingComment" value="#{sharing.subCommentList}">
<p:commandLink id="cl1" value="" process="@this" action="#{reportController.reportSharingComment(sharingComment)}" style="float:right;" id="sharingComment_alert" styleClass="icon_alert" title="#{msg['label.report']}" update=":messages" >
</p:commandLink>
<p:commandLink value="" id="cl2" process="@this" action="#{sharingController.deleteComment(sharingComment)}" style="float:right;" id="sharingComment_delete" styleClass="icon_delete" title="#{msg['label.delete']}" update="@form :messages">
</p:commandLink>
</ui:repeat>
</ui:repeat>
</h:form>
</ui:composition>
我一个具体的名单后结构试图在嵌套ui:repeat
然后commandlinks被解雇了,但我必须遍历像每一个在myList
共享子commentlists场名单。我正在加载myList
和每次共享我加载subCommentlist
在一个for后构造,但我仍然不能使commandLink
的火灾。
您能否只发表相关的代码? “”标签中有数百行标记完全不必要。 –
2013-02-08 15:44:40
有时,SO成员会告诉分享一切以找出问题,我将删除'ui:remove's – merveotesi 2013-02-08 16:21:17
您确定这个组件不在另一个''的右边吗?因为这将是'form'嵌套,所以你的'UIInput's不起作用。此外,下次只需发布相关代码以重现问题,而不是整个代码。更多信息:[h:commandLink/h:commandButton未被调用](http://stackoverflow.com/q/2118656/1065197) –
2013-02-08 16:42:20