When call 'endEdit' method to end a editing row, the row data is only updated in memory, you have to post the updated row to remote server manually. The code below shows how to end editing a treegrid row and save it to the remote server(maybe a mysql database).
var id = ... // the node id
$('#tg').treegrid('endEdit', id);
var row = $('#tg').treegrid('find', id); // find the row data
$.post(yoururl, row, function(result){ // post the row to remote server
//...
});