kpfalzer
4 Nov 2012, 3:38 PM
I use Ext.ux.grid.TransformGrid to create a grid, referencing a table in the HTML code:
var grid2 = Ext.create('Ext.ux.grid.TransformGrid', 'msgTable', {
title: 'Message Summary',
stripeRows: true,
height: 130
});
and the table (snippet from HTML code):
<table hidden id="msgTable" class="x-hidden">
<col id="code"> <col id="count"> <col id="error"> <col id="warn">
...
<thead>
...
In my code, grid2 is added to an Ext.Panel, etc.
The table renders fine and the manual sort controls work fine, too.
However, I would like the table to be initially sorted in DESC order by 'warn' then by DESC order by 'error'.
I looked through many examples, but did not find any which showed how to initial sorting; esp. when using a TransformGrid to create the grid.
var grid2 = Ext.create('Ext.ux.grid.TransformGrid', 'msgTable', {
title: 'Message Summary',
stripeRows: true,
height: 130
});
and the table (snippet from HTML code):
<table hidden id="msgTable" class="x-hidden">
<col id="code"> <col id="count"> <col id="error"> <col id="warn">
...
<thead>
...
In my code, grid2 is added to an Ext.Panel, etc.
The table renders fine and the manual sort controls work fine, too.
However, I would like the table to be initially sorted in DESC order by 'warn' then by DESC order by 'error'.
I looked through many examples, but did not find any which showed how to initial sorting; esp. when using a TransformGrid to create the grid.