EasyUI Forum

General Category => General Discussion => Topic started by: Pierre on April 25, 2016, 05:09:30 AM



Title: [SOLVED] How to get row value
Post by: Pierre on April 25, 2016, 05:09:30 AM
Hello
I'm using scrollview and cellediting extensions.
On the onBeforeCellEdit(index,field) I have this code:
Code:
	var row = $(this).datagrid('getRows')[index];
        alert(row);
problem is - 'row' return object value only on first 99 rows(on current page) - and for row's below that it returns 'undefined'.
Question is - how to get row value (for selected cell) when clicking on cell on any page?
Thank you.


Title: Re: How to get row value
Post by: jarry on April 25, 2016, 08:07:17 AM
Please call 'getRow' method to get the specified row data. This method is defined in scrollview.
Code:
onBeforeCellEdit: function(index,field){
    var row = $(this).datagrid('getRow', index);
    console.log(row)
}


Title: Re: How to get row value
Post by: Pierre on April 25, 2016, 09:34:17 AM
Awesome. I did not read the doc's  :o
Thank you so much.