when using the filter, the links of the rows doesn't work

UI Components for JSF
danilo.balarini
Posts: 2
Joined: 05 May 2010, 16:44

05 May 2010, 17:49

Hello all, this is my first post,

I created a simple datatable, and put some columns on it. All perfect, except for when i use the filter, the links in the rows doesn't work anymore. Seems that they lose the reference of the row.

List.xhtml (only the datatable part)

Code: Select all

                    <p:dataTable var="item" value="#{alertController.items}" paginator="true" 
                                 rows="10" dynamic="true" emptyMessage="#{bundle.ListAlertEmpty}"
                                 errorMessage="#{bundle.ListAlertError}" loadingMessage="#{bundle.LoadingMessage}"
                                 paginatorTemplate="{PreviousPageLink} {NextPageLink} {RowsPerPageDropdown}" rowsPerPageTemplate="10,15,20"
                                 nextPageLinkLabel="#{bundle.Next}" previousPageLinkLabel="#{bundle.Previous}">

                        <p:column filterBy="#{item.idAlert}">
                            <f:facet name="header">
                                <h:outputText value="#{bundle.ListAlertTitle_idAlert}"/>
                            </f:facet>
                            <h:outputText value="#{item.idAlert}"/>
                        </p:column>

                        <p:column filterBy="#{item.alertDescription}" resizable="true">
                            <f:facet name="header">
                                <h:outputText value="#{bundle.ListAlertTitle_alertDescription}"/>
                            </f:facet>
                            <h:outputText value="#{item.alertDescription}"/>
                        </p:column>

                        <p:column filterBy="#{item.alertName}" resizable="true">
                            <f:facet name="header">
                                <h:outputText value="#{bundle.ListAlertTitle_alertName}"/>
                            </f:facet>
                            <h:outputText value="#{item.alertName}"/>
                        </p:column>

                        <p:column>
                            <f:facet name="header">
                                <h:outputText value="&nbsp;"/>
                            </f:facet>
                            <h:commandLink action="#{alertController.prepareView}">
                             <p:graphicImage alt="#{bundle.AltView}" value="../resources/imagens/Info.png" height="18" width="18" />
                            </h:commandLink>
                            <h:outputText value=" "/>
                            <h:commandLink action="#{alertController.prepareEdit}">
                             <p:graphicImage alt="#{bundle.AltEdit}" value="../resources/imagens/Edit.png" height="18" width="18" />
                            </h:commandLink>
                            <h:outputText value=" "/>
                            <h:commandLink action="#{alertController.destroy}" onclick="return confirm('#{bundle.ConfirmOperation}')">
                             <p:graphicImage alt="#{bundle.AltDestroy}" value="../resources/imagens/Close.png" height="18" width="18" />
                            </h:commandLink>
                        </p:column>
                    </p:dataTable>
AlertController.java

Code: Select all

package com.br.xxxxxx.yyyyy.view;

import com.br.xxxxxx.yyyyy.model.Alert;
import com.br.xxxxxx.yyyyy.view.util.JsfUtil;
import com.br.xxxxxx.yyyyy.view.util.PaginationHelper;
import com.br.xxxxxx.yyyyy.controller.AlertFacade;

import java.util.ResourceBundle;
import javax.ejb.EJB;
import javax.faces.bean.ManagedBean;
import javax.faces.bean.SessionScoped;
import javax.faces.component.UIComponent;
import javax.faces.context.FacesContext;
import javax.faces.convert.Converter;
import javax.faces.convert.FacesConverter;
import javax.faces.model.DataModel;
import javax.faces.model.ListDataModel;
import javax.faces.model.SelectItem;

@ManagedBean (name="alertController")
@SessionScoped
public class AlertController {

    private Alert current;
    private DataModel items = null;
    @EJB private com.br.xxxxx.yyyyy.controller.AlertFacade ejbFacade;
    private PaginationHelper pagination;
    private int selectedItemIndex;

    public AlertController() {
    }

    public Alert getSelected() {
        if (current == null) {
            current = new Alert();
            selectedItemIndex = -1;
        }
        return current;
    }

    private AlertFacade getFacade() {
        return ejbFacade;
    }

    public PaginationHelper getPagination() {
        if (pagination == null) {
            pagination = new PaginationHelper(10) {

                @Override
                public int getItemsCount() {
                    return getFacade().count();
                }

                @Override
                public DataModel createPageDataModel() {
                    return new ListDataModel(getFacade().findRange(new int[]{getPageFirstItem(), getPageFirstItem()+getPageSize()}));
                }
            };
        }
        return pagination;
    }

    public String prepareList() {
        recreateModel();
        return "List";
    }

    public String prepareView() {
        current = (Alert)getItems().getRowData();
        selectedItemIndex = pagination.getPageFirstItem() + getItems().getRowIndex();
        return "View";
    }

    public String prepareCreate() {
        current = new Alert();
        selectedItemIndex = -1;
        return "Create";
    }

    public String create() {
        try {
            getFacade().create(current);
            JsfUtil.addSuccessMessage(ResourceBundle.getBundle("/Bundle").getString("AlertCreated"));
            return prepareView();
        } catch (Exception e) {
            JsfUtil.addErrorMessage(e, ResourceBundle.getBundle("/Bundle").getString("PersistenceErrorOccured"));
            return null;
        }
    }

    public String prepareEdit() {
        current = (Alert)getItems().getRowData();
        selectedItemIndex = pagination.getPageFirstItem() + getItems().getRowIndex();
        return "Edit";
    }

    public String update() {
        try {
            getFacade().edit(current);
            JsfUtil.addSuccessMessage(ResourceBundle.getBundle("/Bundle").getString("AlertUpdated"));
            return "View";
        } catch (Exception e) {
            JsfUtil.addErrorMessage(e, ResourceBundle.getBundle("/Bundle").getString("PersistenceErrorOccured"));
            return null;
        }
    }

    public String destroy() {
        current = (Alert)getItems().getRowData();
        selectedItemIndex = pagination.getPageFirstItem() + getItems().getRowIndex();
        performDestroy();
        recreateModel();
        return "List";
    }

    public String destroyAndView() {
        performDestroy();
        recreateModel();
        updateCurrentItem();
        if (selectedItemIndex >= 0) {
            return "View";
        } else {
            // all items were removed - go back to list
            recreateModel();
            return "List";
        }
    }

    private void performDestroy() {
        try {
            getFacade().remove(current);
            JsfUtil.addSuccessMessage(ResourceBundle.getBundle("/Bundle").getString("AlertDeleted"));
        } catch (Exception e) {
            JsfUtil.addErrorMessage(e, ResourceBundle.getBundle("/Bundle").getString("PersistenceErrorOccured"));
        }
    }

    private void updateCurrentItem() {
        int count = getFacade().count();
        if (selectedItemIndex >= count) {
            // selected index cannot be bigger than number of items:
            selectedItemIndex = count-1;
            // go to previous page if last page disappeared:
            if (pagination.getPageFirstItem() >= count) {
                pagination.previousPage();
            }
        }
        if (selectedItemIndex >= 0) {
            current = getFacade().findRange(new int[]{selectedItemIndex, selectedItemIndex+1}).get(0);
        }
    }

    public DataModel getItems() {
        if (items == null) {
            items = getPagination().createPageDataModel();
        }
        return items;
    }
    
    

    private void recreateModel() {
        items = null;
    }

    public String next() {
        getPagination().nextPage();
        recreateModel();
        return "List";
    }

    public String previous() {
        getPagination().previousPage();
        recreateModel();
        return "List";
    }

    public SelectItem[] getItemsAvailableSelectMany() {
        return JsfUtil.getSelectItems(ejbFacade.findAll(), false);
    }

    public SelectItem[] getItemsAvailableSelectOne() {
        return JsfUtil.getSelectItems(ejbFacade.findAll(), true);
    }

    @FacesConverter(forClass=Alert.class)
    public static class AlertControllerConverter implements Converter {

        public Object getAsObject(FacesContext facesContext, UIComponent component, String value) {
            if (value == null || value.length() == 0) {
                return null;
            }
            AlertController controller = (AlertController)facesContext.getApplication().getELResolver().
                    getValue(facesContext.getELContext(), null, "alertController");
            return controller.ejbFacade.find(getKey(value));
        }

        java.lang.Integer getKey(String value) {
            java.lang.Integer key;
            key = Integer.valueOf(value);
            return key;
        }

        String getStringKey(java.lang.Integer value) {
            StringBuffer sb = new StringBuffer();
            sb.append(value);
            return sb.toString();
        }

        public String getAsString(FacesContext facesContext, UIComponent component, Object object) {
            if (object == null) {
                return null;
            }
            if (object instanceof Alert) {
                Alert o = (Alert) object;
                return getStringKey(o.getIdAlert());
            } else {
                throw new IllegalArgumentException("object " + object + " is of type " + object.getClass().getName() + "; expected type: "+AlertController.class.getName());
            }
        }

    }

}
Happens that way - When NOT using the filter:
Image

And when using the filter:
Image

And here is the stack trace:

Code: Select all

javax.faces.el.EvaluationException: javax.faces.model.NoRowAvailableException
	at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
	at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
	at javax.faces.component.UICommand.broadcast(UICommand.java:315)
	at javax.faces.component.UIData.broadcast(UIData.java:912)
	at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:775)
	at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1267)
	at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
	at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
	at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
	at javax.faces.webapp.FacesServlet.service(FacesServlet.java:312)
	at org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1523)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:279)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:188)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:641)
	at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:97)
	at com.sun.enterprise.web.PESessionLockingStandardPipeline.invoke(PESessionLockingStandardPipeline.java:85)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:185)
	at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:332)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:233)
	at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:239)
	at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:791)
	at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:693)
	at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:954)
	at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:170)
	at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:135)
	at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:102)
	at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:88)
	at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:76)
	at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:53)
	at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:57)
	at com.sun.grizzly.ContextTask.run(ContextTask.java:69)
	at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:330)
	at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:309)
	at java.lang.Thread.run(Thread.java:619)
Caused by: javax.faces.model.NoRowAvailableException
	at javax.faces.model.ListDataModel.getRowData(ListDataModel.java:150)
	at com.br.xxxxx.yyyyy.view.AlertController.prepareEdit(AlertController.java:92)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at com.sun.el.parser.AstValue.invoke(AstValue.java:234)
	at com.sun.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:297)
	at com.sun.faces.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:98)
	at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
	... 33 more
Hope I was clear. And hope you can help me!
Regards
Danilo - Brazil

danilo.balarini
Posts: 2
Joined: 05 May 2010, 16:44

05 May 2010, 18:51

Solved.

the datatable's atribute dynamic must be changed to false in order to work.
Now it's fine.

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

07 May 2010, 09:35

Hi Danilo,

As it should also work in dynamic mode, I've created a bug ticket for this;

http://code.google.com/p/primefaces/iss ... ail?id=800

If you star it, you can get email notifications.

Thanks for the detailed post.

giovanibad
Posts: 10
Joined: 24 May 2010, 03:29

13 Jul 2010, 21:01

Any news about this issue, I am having the same problem?

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

14 Jul 2010, 18:53

We have pushed all datatable related issues to 2.1.1 which will introduce the new datatable.

eltonmorais
Posts: 1
Joined: 19 Mar 2011, 22:48

28 Apr 2011, 19:23

Hi. I am having the same problem when using filter and then... call a view's row from datatable.
I tried change the attribute dynamic from true to false but in both of cases does not work. I have a look in ticket issues but I'm using the primefaces 2.2.1 version and the problem continues.

This is the controller class:

Code: Select all

import model.ObjetoPessoa;
import jsf.controller.util.JsfUtil;
import jsf.controller.util.PaginationHelper;
import bean.ObjetoPessoaFacade;
import java.io.Serializable;

import java.util.ResourceBundle;
import javax.ejb.EJB;
import javax.faces.bean.ManagedBean;
import javax.faces.bean.SessionScoped;
import javax.faces.component.UIComponent;
import javax.faces.context.FacesContext;
import javax.faces.convert.Converter;
import javax.faces.convert.FacesConverter;
import javax.faces.model.DataModel;
import javax.faces.model.ListDataModel;
import javax.faces.model.SelectItem;

@ManagedBean(name = "objetoPessoaController")
@SessionScoped
public class ObjetoPessoaController implements Serializable {

    private ObjetoPessoa current;
    private DataModel items = null;
    @EJB
    private bean.ObjetoPessoaFacade ejbFacade;
    private PaginationHelper pagination;
    private int selectedItemIndex;
    private boolean isAnySelected;

    public ObjetoPessoaController() {
    }

    public ObjetoPessoa getSelected() {
        if (current == null) {
            current = new ObjetoPessoa();
            selectedItemIndex = -1;
        }
        return current;
    }


    private ObjetoPessoaFacade getFacade() {
        return ejbFacade;
    }

    public PaginationHelper getPagination() {
        if (pagination == null) {
            pagination = new PaginationHelper(10) {

                @Override
                public int getItemsCount() {
                    return getFacade().count();
                }

                @Override
                public DataModel createPageDataModel() {
                    //return new ListDataModel(getFacade().findRange(new int[]{getPageFirstItem(), getPageFirstItem() + getPageSize()}));
                    return new ListDataModel(getFacade().findAll());
                }
            };
        }
        return pagination;
    }

    public String prepareList() {
        recreateModel();
        return "List";
    }

    public String prepareListForMenu() {
        recreateModel();
        return "/pages/objetoPessoa/List.xhtml";
    }

    public String prepareView() {
        current = (ObjetoPessoa) getItems().getRowData();
        selectedItemIndex = pagination.getPageFirstItem() + getItems().getRowIndex();
        return "View";
    }

    public String prepareDestroy() {
        current = (ObjetoPessoa) getItems().getRowData();
        selectedItemIndex = pagination.getPageFirstItem() + getItems().getRowIndex();
        return "Destroy";
    }

    public String prepareCreate() {
        current = new ObjetoPessoa();
        selectedItemIndex = -1;
        return "Create";
    }

    public String create() {
        try {
            getFacade().create(current);
            JsfUtil.addSuccessMessage(ResourceBundle.getBundle("/Bundle").getString("ObjetoPessoaCreated"));
            return prepareCreate();
        } catch (Exception e) {
            JsfUtil.addErrorMessage(e, ResourceBundle.getBundle("/Bundle").getString("PersistenceErrorOccured"));
            return null;
        }
    }

    public String prepareEdit() {
        current = (ObjetoPessoa) getItems().getRowData();
        selectedItemIndex = pagination.getPageFirstItem() + getItems().getRowIndex();
        return "Edit";
    }

    public String update() {
        try {
            getFacade().edit(current);
            JsfUtil.addSuccessMessage(ResourceBundle.getBundle("/Bundle").getString("ObjetoPessoaUpdated"));
            return "View";
        } catch (Exception e) {
            JsfUtil.addErrorMessage(e, ResourceBundle.getBundle("/Bundle").getString("PersistenceErrorOccured"));
            return null;
        }
    }

    public String destroy() {
        current = (ObjetoPessoa) getItems().getRowData();
        selectedItemIndex = pagination.getPageFirstItem() + getItems().getRowIndex();
        performDestroy();
        recreateModel();
        return "List";
    }

    public String destroyAndView() {
        performDestroy();
        recreateModel();
        updateCurrentItem();
        return "List";

    }

    private void performDestroy() {
        try {
            getFacade().remove(current);
            JsfUtil.addSuccessMessage(ResourceBundle.getBundle("/Bundle").getString("ObjetoPessoaDeleted"));
        } catch (Exception e) {
            JsfUtil.addErrorMessage(e, ResourceBundle.getBundle("/Bundle").getString("PersistenceErrorOccured"));
        }
    }

    private void updateCurrentItem() {
        int count = getFacade().count();
        if (selectedItemIndex >= count) {
            // selected index cannot be bigger than number of items:
            selectedItemIndex = count - 1;
            // go to previous page if last page disappeared:
            if (pagination.getPageFirstItem() >= count) {
                pagination.previousPage();
            }
        }
        if (selectedItemIndex >= 0) {
            current = getFacade().findRange(new int[]{selectedItemIndex, selectedItemIndex + 1}).get(0);
        }
    }

    public DataModel getItems() {
        if (items == null) {
            items = getPagination().createPageDataModel();
        }
        return items;
    }

    private void recreateModel() {
        items = null;
    }

    public String next() {
        getPagination().nextPage();
        recreateModel();
        return "List";
    }

    public String previous() {
        getPagination().previousPage();
        recreateModel();
        return "List";
    }

    public SelectItem[] getItemsAvailableSelectMany() {
        return JsfUtil.getSelectItems(ejbFacade.findAll(), false);
    }

    public SelectItem[] getItemsAvailableSelectOne() {
        return JsfUtil.getSelectItems(ejbFacade.findAll(), true);
    }

    @FacesConverter(forClass = ObjetoPessoa.class)
    public static class ObjetoPessoaControllerConverter implements Converter {

        public Object getAsObject(FacesContext facesContext, UIComponent component, String value) {
            if (value == null || value.length() == 0) {
                return null;
            }
            ObjetoPessoaController controller = (ObjetoPessoaController) facesContext.getApplication().getELResolver().
                    getValue(facesContext.getELContext(), null, "objetoPessoaController");
            return controller.ejbFacade.find(getKey(value));
        }

        java.lang.Integer getKey(String value) {
            java.lang.Integer key;
            key = Integer.valueOf(value);
            return key;
        }

        String getStringKey(java.lang.Integer value) {
            StringBuffer sb = new StringBuffer();
            sb.append(value);
            return sb.toString();
        }

        public String getAsString(FacesContext facesContext, UIComponent component, Object object) {
            if (object == null) {
                return null;
            }
            if (object instanceof ObjetoPessoa) {
                ObjetoPessoa o = (ObjetoPessoa) object;
                return getStringKey(o.getId());
            } else {
                throw new IllegalArgumentException("object " + object + " is of type " + object.getClass().getName() + "; expected type: " + ObjetoPessoaController.class.getName());
            }
        }
    }
}
This is the list page:

Code: Select all

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:p="http://primefaces.prime.com.tr/ui">

    <ui:composition template="/template.xhtml">

        <ui:define name="main">

            <h2>Pessoas</h2>

            <h:form styleClass="jsfcrud_list_form">

                <h:panelGroup id="messagePanel" layout="block">
                    <p:growl showDetail="true"/>
                </h:panelGroup>

                <h:outputText escape="false" value="#{bundle.ListObjetoPessoaEmpty}" rendered="#{objetoPessoaController.items.rowCount == 0}"/>

                <h:panelGroup rendered="#{objetoPessoaController.items.rowCount > 0}">

                    <p:dataTable  widgetVar="tabela_pessoas"
                                  value="#{objetoPessoaController.items}"
                                  var="item"
                                  paginator="true"
                                  rows="10"
                                  paginatorTemplate="{CurrentPageReport}  {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown}"
                                  rowsPerPageTemplate="10,20,30,50"
                                  dynamic="false">

                        <p:column headerText="#{bundle.ListObjetoPessoaTitle_id}"
                                  filterBy="#{item.id}"                                  
                                  >
                            <h:outputText value="#{item.id}"/>
                        </p:column>

                        <p:column headerText="#{bundle.ListObjetoPessoaTitle_nm}"
                                  filterBy="#{item.nm}"

                                  >
                            <h:outputText value="#{item.nm}"/>
                        </p:column>

                        <p:column headerText="#{bundle.ListObjetoPessoaTitle_icAtiva}"
                                  filterBy="#{item.icAtiva}"

                                  >
                            <h:outputText value="#{item.icAtiva}"/>
                        </p:column>

                        <p:column>
                            <h:commandButton value="visualizar" image="view_16.png" action="#{objetoPessoaController.prepareView()}" title="#{bundle.ListObjetoPessoaViewLink}" />
                            <p:spacer width="5" />
                            <h:commandButton image="edit_16.png"  action="#{objetoPessoaController.prepareEdit}" title="#{bundle.ListObjetoPessoaEditLink}" />
                            <p:spacer width="5" />
                            <h:commandButton image="delete_16.png" action="#{objetoPessoaController.prepareDestroy()}" title="#{bundle.ListObjetoPessoaDestroyLink}" />
                        </p:column>

                    </p:dataTable>

                </h:panelGroup>

            </h:form>

        </ui:define>

    </ui:composition>

</html>
Can someone give a help?

Thanks!

Tan Chin Sheng
Posts: 4
Joined: 27 May 2011, 05:49

27 May 2011, 05:59

DataModel doesn't work in many things with datatable. I tried not to change too much of my managed bean. Sorting was not working, ended up only able to use filtering. After filtering, faced the same problem not able to activate the link. Please help. I hope Primefaces can quickly find a extension of the DataModel.
Primefaces2.2.1/JSF2/EJB3.1/JPA2/NB7/Glassfish

User avatar
mediterran81
Posts: 29
Joined: 22 Mar 2011, 12:14
Location: France
Contact:

21 Jun 2011, 01:12

Same problem here.
When using

Code: Select all

 List
instead of

Code: Select all

DataModel
, the filtering and sorting work perfectly and row selection is fine.

I tried several means but in vain, when you succeed to filter a datatable and click on acommandButton or Linkto perform an action, you get a NoAvailableRowException.
I tried OpenFaces datatable filtering and it works fine, on both LIST AND DATAMODEL.

It is so sad the problem is not even solved in PrimeFaces 3.0M :(
And I don't know of any other means to filter a primefaces datatable for now. That is critical if the end user wants to filter a table and then export the filter datatable using PrimeFaces exporter.

kukeltje
Expert Member
Posts: 9605
Joined: 17 Jun 2010, 13:34
Location: Netherlands

21 Jun 2011, 23:21

It is so sad the problem is not even solved in PrimeFaces 3.0M :(
Then buy commercial support.... 2 days pay for it is maybe better than 5 days struggling :-)

william25
Posts: 1
Joined: 29 May 2012, 18:04

29 May 2012, 21:40

Hi I have the same error, which after filtering and make a method out javax.servlet.ServletException: javax.faces.model.NoRowAvailableException

any solution.

primefaces 3.2

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 15 guests