Running into a little issue:
I have an "Add row" button item in the toolbar with a listener like the following:
listener:{
click:function(evt,ui){
var $grid = $(this).closest('.pq-grid');
addRow($grid,{
id:null,
name:null,
group_rate:0,
disabled:false,
tax_rates:[]
});
}
}
(The "addRow" function, incase you need to see it:)
function addRow($grid,rowData){
if(isEditing($grid)){
return;
}
// append empty row in first row.
var rowOptions = {
rowIndxPage:0,
rowData:rowData
}
if(typeof rowData == 'function'){
rowOptions.rowData = rowData();
}
$grid.pqGrid('addRow',rowOptions);
var $tr = $grid.pqGrid('getRow',{
rowIndxPage:0
});
if($tr){
$tr.find('button.edit_btn').first().click();
}
}
The problem is with the "group_rate" entry. It never seems to show up in the rowData for the new row, although it does show for rows that were pulled from a JSON API. If I rename it to "fgroup_rate", then it will show -- but I'd like to use the name the server side API is returning, "group_rate".
Is "group_*" a reserved name in pqGrid?