In migrating an app from 3.2 to 4.0 I have a piece that isn't working. It is an application that reads a grid to export it to Excel, I read the grid itself so that the Excel file has the same sorting as the user has on the grid at the moment. The code is below. I added the console.log() and it is showing 'theData' as undefined. Do I need to get the data from the grid in a different way now?
Thanks,
Scott
Thanks,
Scott
Code:
var exportToSS = function() { var theData = customerGrid.view.getRecords(customerGrid.view.getNodes()); console.log(theData); // Build the JSON of the grid to send back to server. stuff = '['; Ext.Array.forEach(theData, function(item, index, allItems) { stuff += '{"INVDCUST":' + item.get('INVDCUST') + ',"TUNAME":' + item.get('TUNAME') + ',"TOTALSUM":' + item.get('TOTALSUM') + ',"DAYSTOPAY":' + item.get('DAYSTOPAY') + ',"HOWMANY":' + item.get('HOWMANY') + ',"RPM":' + item.get('RPM') + ',"FSCRPM":' + item.get('FSCRPM') + ',"LHRPM":' + item.get('LHRPM') + '},'; } ); stuff += ']';
Comment