0

Is it possible at all to set up a DataTable in PrimeVue where rowGroupMode is set to rowspan and groupRowsBy is done on multiple columns? For example:

enter image description here

Time and User always span the same number of rows.

Taking this as a starting example https://primevue.org/datatable/#rowgroup_rowspan.

Thank you in advance.

2

1 Answer 1

0

One can indeed add an array of field names to groupRowsBy

<DataTable :value="obj" rowGroupMode="rowspan" :groupRowsBy="['timestamp', 'user']">

Just a word of warning, there is no hierarchy to the grouping, so the final results may not be as expected, unless one introduces an additional, let's call it, "private property" for grouping.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.