1 Reply Latest reply on Feb 23, 2009 12:25 PM by Nick Belaevski

    How add new row in datatable or...?

    Armen Arzumanyan Newbie

      Hello All, I am new in rich faces, I have one problem.
      I must add new row in the page, fill and save,

      it can be datatable.

      <h:dataTable value="#{taxsystemCountry.taxsystemCountryItems}" var="item">
       <h:column>
       <f:facet name="header">
       <h:outputText value="Uid"/>
       </f:facet>
       <h:outputText value=" #{item.uid}"/>
       </h:column>
       <h:column>
       <f:facet name="header">
       <h:outputText value="Code"/>
       </f:facet>
       <h:outputText value=" #{item.code}"/>
       </h:column>
       <h:column>
       <f:facet name="header">
       <h:outputText value="Name"/>
       </f:facet>
       <h:outputText value=" #{item.name}"/>
       </h:column>
      ....................
      </h:dataTable>
      
       <h:commandButton id="add" action="#{bean.addNewDataItem}" value="ADD ROW" />
       <h:commandButton id="save" action="#{bean.save}" value="Save" />.......
      


      I want use rich datatable /panel, how can I add new same row(name, lastname....?

      what is the right way?
      ?

      <rich:inplaceInput defaultLabel="click to enter "
      showControls="true"/>