2 Replies Latest reply on Oct 19, 2009 7:07 AM by Nicole Schweighardt

    ReRender problem with link inside datatable

    Nicole Schweighardt Novice

      I use facelets 1.1.15B1, jsf ri 1.2, richfaces 3.2.2 GA.

      I have got a menu where you can select a group:

      <h:selectOneMenu value="#{appBean.currentGroupId}">
       <f:selectItems value="#{appBean.groupsForStudentAsItems}" />
       <a4j:support event="onchange" reRender="appointmentsForChosenGroup,ask_for_app,offeredAppointments" ajaxSingle="true" />

      Belonging to the selected group there appear several areas. One with a normal h:commandLink, several with dataTables with links inside of them.

      Here is the one with the normal link. It works after reRendering.
      <a4j:outputPanel layout="block" id="ask_for_app" >
      <h:commandLink value="#{rs.menu_ask_for_appointments}" action="#{appBean.showAskForAppointments}" rendered="#{appBean.projectManager}" >
      <f:param value="#{appBean.currentGroup.title}" />

      Here is one of the areas with the rich:dataTables.
      <a4j:outputPanel layout="block" id="offeredAppointments">
      <rich:dataTable value="#{appBean.appointmentOffersForCurrentGroup}" var="offer" reRender="ds"...>
      <f:facet name="header">
       <h:outputText value="#{rs.appointment_offer_title}"/>
       <!-- ........more columns -->
      <f:facet name="header">
       <h:outputText value="#{rs.actions}"/>
      <!-- edit link -->
      <h:commandLink alt="#{rs.edit}" action="#{appBean.showEditAppointmentOffer}" rendered="#{appBean.projectManager}">
       <ns:editTooltip />
       <f:param name="appointmentOfferId" value="#{offer.id}" />

      The Tag ns:editTooltip is a tag that I defined. It only is a layout thing.
      With facelets and ui:composition there is inserted the following:

      <rich:panel id="tooltip_edit" styleClass="rich-quick-info">
       <h:graphicImage value="/img/buttons/edit.png"/>
       <span style="white-space:nowrap">
       <h:outputText value="#{rs.edit}" />

      The problem is that when the page is rerendered, the edit link in the 3rd listing is not clickable anymore.

      I hope you have got an idea?
      I would be very happy.
      Thanks a lot