Hi Everyone,

I have a little big problem,  I got a CRUD like app, in the main form I have
a data table that shows the result of a query and every row has a link to
jump to the edit page, everything works fine, until I try to go to the next
page *h:commandLink action="#{backingBean.edit}"  *with the selected row so
I can edit it, the problems kicks in when I remove a line of code that I
have in the getObjectList method
* objectList = manager.findAll();
*
I remove it because I need that the main page doesn't show anything until
the search button is clicked, after this modification the links stop
working, I cannot get to the nex page, in Debug mode I see I don't even get
to the edit() methond in the backing bean, is like the bean is recreated
before the action of the h:commandLink kicks and then the table data and the
row are null so they don't fire any event :S

The BackingBean scope is Request (it work with session scope but I don't
think is necesary to hold on that bean for a whole session )
and I have try with* <f:param* ,   *<f:attribute*,  *
<f:setPropertyActionListener*  all works untill I remove that line....


*What Can I do??*

Code below..
*                                <t:dataTable id="perfilesTable"
width="100%" border="0" rows="20"
                                    cellpadding="5" cellspacing="1"
value="#{backingBean.objectList}"
                                    var="selectedRow" rowClasses="row1,
row2"   headerClass="tableHead">
                                    <t:column>
                                           <f:facet name="header">
                                                  <h:outputText
value="Perfiles"/>
                                            </f:facet>
                                                <h:commandLink
action="#{backingBean.edit}" value="#{selectedRow.name}"
actionListener="#{backingBean.editAction}">
                                                    <f:attribute
name="attributeName1" value="#{selectedRow}" />
                                                </h:commandLink>
                                    </t:column>
                                    <t:column>
                                        <f:facet name="header">
                                                <h:outputText
value="Active"/>
                                        </f:facet>
                                        <h:outputText
value="#{selectedRow.active}"/>
                                    </t:column>
                                </t:dataTable>
*

Cordialmente,


Marcus V. Sánchez D.
______________________
Enterprise Developer.
Sun Certified Java Programmer (SCJP)

Reply via email to