I am using following code and trying to make each row clickable and set some event of top of that.
<table width="100%" class="TableSpace">
<ui:repeat var="damageinfo"
value="#{DamageDetails2.damageInfoAll}" varStatus="status">
<h:commandLink>
<tr class="row1 lineBorder" onclick="alert('Hello')">
<td height="40">
<h:outputText
value="#{damageinfo.damageID}" styleClass="LabelClass">
</h:outputText>
</td>
<td height="40">
<h:outputText
value="#{damageinfo.damageName}" styleClass="valueClass">
</h:outputText>
</td>
</tr>
<f:setPropertyActionListener target="#{carDetails.rootImage}"
value="#{carDetails.carUrl2}" />
<f:setPropertyActionListener target="#{carDetails.view}"
value="#{carDetails.viewDetails['carUrl2']}" />
<f:ajax event="action" render="ViewId" />
</h:commandLink>
</ui:repeat>
</table>
But it does not work. How is this caused and how can I solve it?