Example Editable DataTable

UI Components for JSF
Post Reply
User avatar
bumble.bee
Posts: 723
Joined: 29 Sep 2010, 21:39
Location: United States

08 Oct 2010, 20:41

Can someone please post an example of how to use the Editable DataTable to persist changes to a database?

I'm stumbling with the rowEditListener and RowEditEvent.

Using the rowEditListener attribute of the dataTable I can register a method to be notified of RowEditEvents. However If I use System.out.print to display the attributes of the RowEditEvent (Source, Component, Object) it appears nothing has changed. The managed bean which maintains the list of model objects is also unchanged. The browser view will show the updated value until I refresh the page.

I'm using JPA Entities for my domain objects and the managed bean for the view is a stateful EJB with Conversation scope (I'm also using CDI).

My Environment:
  • Java 1.6.0_21 64-bit
  • GlassFish 3.0.1
  • JSF Mojarra 2.0.2
  • PF 2.2.RC1-SNAPSHOT

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 44 guests