Add same column twice (material-ui data grid)
jozef-slezak opened this issue · comments
Goal: generate unique columns id/field for the same column
Background: MaterialUI Data Grid -field is the only required property since it's the column identifier.
Requirements
- check if the column id (field) is allready present (for example
{ field: "name"
)
valueGetter - use
{ field: "name", valueGetter
if the entity does not contain unique columne id - use suffix: 2, 3, 4 (for example
{ field: "name"...
) for column id (field) if the field is allready present in columns - ability to define columnId (use case: user could define "fullName" concantenated from first name and last name)
API
- extend existing API addColumn parameters options with new optional
columnId