This is a migrated thread and some comments may be shown as answers.

Include field & command in 1 column of Grid?

3 Answers 326 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Bryan
Top achievements
Rank 1
Bryan asked on 24 May 2016, 01:19 PM

Hi 

Is it possible to have a command and field in 1 column of a Grid? Something along the lines of::

Where in line number 11 below the 3 column would include the data value for products and a button (in this case just to edit the products for 1 line in grid) 

01.var grid = $("#grid").kendoGrid({
02.     dataSource: {
03.          pageSize: 20,
04.          data: createRandomData(50)
05.     },
06.     pageable: true,
07.     height: 550,
08.     columns: [
09.          { field: "FirstName", title: "First Name", width: "140px" },
10.          { field: "LastName", title: "Last Name", width: "140px" },
11.          { field: "products", command: { text: "Edit Product List", click: showDetails }, title: " ", width: "180px" }                                                  ]
12.}).data("kendoGrid");

 

Thanks in Advance 

 

3 Answers, 1 is accepted

Sort by
0
Accepted
Stephen
Top achievements
Rank 2
answered on 24 May 2016, 07:53 PM

Try using a template for the column instead of a command and style as desired:

http://dojo.telerik.com/uxecI

 

 

0
Dimiter Madjarov
Telerik team
answered on 25 May 2016, 08:31 AM

Hello Bryan,

I could confirm that using a template, which displays the field along with the command is the correct way to go here. Is this the desired behavior or we could provide further assistance?

Regards,
Dimiter Madjarov
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Bryan
Top achievements
Rank 1
answered on 31 May 2016, 10:05 AM
Thank You Stephen this is exactly what we were looking for, Regards. 
Tags
Grid
Asked by
Bryan
Top achievements
Rank 1
Answers by
Stephen
Top achievements
Rank 2
Dimiter Madjarov
Telerik team
Bryan
Top achievements
Rank 1
Share this question
or