Title: update row after edit, but the styler property does not change Post by: catpaw on July 12, 2017, 08:50:15 AM hi I have a datagrid with one cell editing:
Code: <th data-options="field:'tag',width:80,align:'center',halign:'center',sortable:true, As you can see, the styler property gets the background color from a row.codigo, so after edit this row I want the background color changes as well. I see the updateRow method, but I cant figure out how use it to change the styler property $('#dg').datagrid('updateRow',{ index: 2, row: { --------------------------------\ name: 'new name',-------------> No need this note: 'new note message'-----/ }--------------------------------------/ styler: row.codigo, -----------------------------> how set the new background color?????? }); Thank you Title: Re: update row after edit, but the styler property does not change Post by: catpaw on July 17, 2017, 08:14:02 AM Well, I assume it's not possible
:-\ Title: Re: update row after edit, but the styler property does not change Post by: stworthy on July 17, 2017, 05:09:37 PM Your styler function relies on the row field value(row.codigo). To change the background color, just change this field value as you want.
Code: styler: function (value,row,index){ You can call the 'updateRow' method to change the field values. Code: $('#dg').datagrid('updateRow',{ |