Hi,
How to protect DataGrid from multiple entries of one record?
I have DataGrid where I have some data (loaded from PHP script).
I add new record by colling the following code
$.post('getData.php?id='+id,
function(data){
$('#trTable').datagrid('insertRow',{
index: 0,
row: jQuery.parseJSON(data)
});
}
);
But if I call this code more then once for the same "id" then I have duplicated lines in my datagrid.
Is there any way to protect datagrid from multiple load of one record?
PS: Yes, I know that I can check data before I insert it. But I wonder if datagrid itself could do this kind of job.