Multiple fields in one column

Hi

I am working on a grid and I have a problem. In order to have a custom display I use a template to group 3 values (Seller, Buyer and Broker), which works perfectly. What I would like to do now is to be able to filter on each value independently. Is it possible in the definition of a column to pass it several fields as in my example below ?

col.HeaderText("Client").Width("150").Template("#templateClient").Field("Seller").Field("Buyer").Field("Broker").TextAlign(TextAlign.Left).ClipMode(ClipMode.EllipsisWithTooltip).Add();

Thanks in advance.


1 Reply

RS Rajapandiyan Settu Syncfusion Team March 11, 2022 05:52 AM UTC

Hi Chaffois, 
 
Thanks for contacting Syncfusion support. 
 
By using the ColumnTemplate feature or valueAccessor API, you can show the customized value in the Grid column. But this is used only for the display purpose. All the Grid actions like Filtering, Searching, Grouping, Sorting, etc., are performed with the Grid’s dataSource value based on its column field name and its type not with the customized value. Also, Grid column does not support multiple field names. This is the intended behavior of EJ2 Grid. 

So, it is not feasible to achieve your requirement in EJ2 Grid.  
 
Regards, 
Rajapandiyan S 


Loader.
Up arrow icon