Questions tagged [primefaces-datatable]

PrimeFaces p:dataTable component related questions

Showcase:

Documentation:

144 questions
2
votes
2 answers

Primefaces - Customize p:confirmDialog content conditionally

I have a list of objects (let's call each object a record object), shown through a component. Each record has a delete button column. When a user clicks on the delete button of the record, a is shown, asking for user…
NickAth
  • 1,089
  • 1
  • 14
  • 35
2
votes
1 answer

Custom facelet does not filter properly

I've got a problem with the column tag in a primeface datatable. I've got a model with a lot of similar fields so in order to reduce code, I'm trying to have a custom made tag to fill each column. So rather having to write something like
willix
  • 686
  • 1
  • 6
  • 13
2
votes
1 answer

How to focus a p:dataTable single selectable row using JavaScript

PrimeFaces has excellent keyboard support. See for example, the showcase of a selectable p:dataTable. When you click a row in the "Single with Row Click" table, you are able to use the arrow keys to navigate rows and use the enter to select the…
Jasper de Vries
  • 19,370
  • 6
  • 64
  • 102
2
votes
0 answers

Primefaces datatable filter issue with retaining object values when filter returns no rows

I am using primefaces(6.2) datatable, while using column filter I am observing a weird behavior, though all the columns (with outputText, inputText) retain the object value, columns with 'selectOneMenu', 'selectBooleanCheckbox' not retaining the…
gannu_lee
  • 283
  • 3
  • 10
2
votes
1 answer

Filter and sorting at the time, Primefaces Datatable error

I'm using a normal datatable on primefaces, but have an error when using both sortBy and filterBy at the same time: javax.faces.FacesException: DataModel must implement org.primefaces.model.SelectableDataModel when selection is enabled. This is how…
2
votes
1 answer

Get p:dataTable column names in bean

Is it possible to get column names as a readable string from data table? I need to get them in my LazyDataModel class. Here's the image of my datatable and columns;
N. Doye
  • 45
  • 9
2
votes
1 answer

How to disable sorting on Primefaces lazy datatable?

I have a datatable with lazy data model and pagination. I want to disable default sorting when I click on "search" button and enable it again when I click on "display" button. So didn't put "sortBy" in my xhtml file and instead, I set it dynamically…
2
votes
1 answer

How to find out whether a DataTable is in row editing state or not in PrimeFaces?

My DataTable's editMode is "row". So, the user clicks on a pencil icon to start editing a row and then clicks a check-mark icon to confirm and end editing. They do the same for some rows and then click on save button to save all edited rows in one…
Mehdi Javan
  • 1,081
  • 6
  • 25
2
votes
4 answers

Right align p:inputNumber in a p:dataTable

I've coded a PrimeFaces (JSF / Java) p:dataTable that uses p:inputNumber for each cell. Everything works, but the table looks ragged due to the left-alignment of p:inputNumber's content. All of the formatting I've tried formats the control itself,…
Stuart Wilson
  • 89
  • 1
  • 6
2
votes
1 answer

PrimeFaces data table paginator does not show at first lazy load

I'm working with PrimeFaces 6.0. I'm creating a data table which uses lazy loading. I have set this.setRowCount(count) in my load method. My paginator is not shown correctly though (it only shows disabled previous, next, begin, end buttons). When I…
Jasper de Vries
  • 19,370
  • 6
  • 64
  • 102
1
vote
1 answer
1
vote
1 answer

Option for DataTableFeatureKey in primefaces 11

In primefaces 6.1 we are using DataTableFeatureKey like below: static Map FEATURES; static { FEATURES = new HashMap(); FEATURES.put(DataTableFeatureKey.FILTER,…
Abhishek
  • 156
  • 1
  • 10
1
vote
1 answer

PrimeFaces ShowcaseUtil class in PF v12 still available?

I can not to find class ShowcasesUtil, that is use to filters, sorting of PrimeFaces LazySorting, LazyFiltering. Example below: public int compare(Customer customer1, Customer customer2) { try { Object value1 =…
1
vote
3 answers

How to merge two cells in a p:dataTable

I'm using PrimeFaces 8.0 and I want to merge the header of the two cells in one header (Title). Is it possible with PrimeFaces to do that? input
1
vote
1 answer

Primefaces 10+ Datatable how to get sorted column from SortEvent?

We are currently using Primefaces version 8 and I am working on migrating us to version 12. In the migration guide 8.0 -> 10.0.0, under DataTable, Breaking changes says this: SortEvent: sorted datatable value is no longer passed to this…
MrChris
  • 86
  • 4
1
2
3
9 10