I have a dgrid that I had originally set up with a renderRow
providerGrid = new dataGrid({
id: 'selectGrid',
selectionMode: 'single',
showHeader: false,
renderRow: renderRowFunction,
loadingMessage: 'Loading data...',
noDataMessage: 'No providers available in this area.'
}, "providerDiv");
When each row is rendered, it's based on several fields and each record is rather tall. I would like to be able to allow the user to see a tabular version, using the same grid, but just change how it's displayed. I haven't been able to figure out how to remove the renderRow parameter.
I have a button that executes a function that will turn on the headers. I tried making a render function that just returned the object without doing any formatting, but that doesn't do anything.
function toggle_GridTable() {
providerGrid.set("showHeader", true);
providerGrid.set('renderRow', renderNothing);
}
function renderNothing (obj, options){
return obj;
}