How to put field value in footer Kendo grid? -


i want value field in grid, , put in footer of grid. there smart way like

       columns: [             {field: "product", title: "product"},             {field: "price", title: "price"},             {field: "pricedoubledinfooter", title:"pricedoubledinfooter",footertemplate:#=price*price#},          ] 

i have prepared simple dojo you: http://dojo.telerik.com/uwovi/2

this shows contact names within demo grid in bootstrap popover when clicked.

without knowing specific needs have included values 1 column popover.

this achieved creating function called getmevalues() assigned footertemplate.

this function following:

  function getmevalues(data)   {     var gridds = $('#grid').data('kendogrid').datasource.data();       var result = '';       gridds.foreach(function(row, index){       result += index + '::' + row.contactname + '<br/>';     });   return '<button class="btn btn-primary" data-container="body" data-toggle="popover" data-title="i data" data-content="' +   result + '"/>' + ' click me</button>'; 

}

i gain access data within datasource grid , iterate on contactname field , add var. create button placed in footer activates popover display contents.

then newly created button function bind popover event within databound event of grid knows activate button me.

obviously change example specific needs if have further questions i'll happy help.


Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

thorough guide for profiling racket code -