Datatable Row Button Events

Hi, I have a weird issue.
This demo http://webix.com/snippet/f84dcea1 works fine, however the same code in my project returns a row id that is about 13 digits long and seems to change everytime I refresh the page!?
My second query is, how do i get the customer ID from the hidden customerID column instead of the row ID?
Thanks, Simon

I managed to sort out the second part of my question, I updated my on_click event with:


$$("mydatatable").on_click.myClass=function(e, id){
  var row = this.getItem(id);
  var customerID = row["customerid"];
};

But the first issue still remains, using just “id” returns a 13 digit number! not the row id?

Component expects that data collection ( grid_data ) will contain id property for each object

var grid_data  [
   { id:"123", title:"some" }
]

if data collection doesn’t contain id property - such id will be auto generated based on the current timestamp (13 digits).

It seems in your case IDs are missed and auto generated.

Oh! Thanks maksim! So instead of using the customerid property, i could just rename it “id”, then change my on_click function back to use just “id”?

Yes, it is the simplest solution.