表の例:
|-Field quantity-|-Field quantity loss-|----Total------|
|-----2----------|-------4-------------|---total=2+4---|
|-----3----------|-------5-------------|---total=3+5---|
extjs の関数でレンダリングできますか?
合計=圃場量+圃場量ロス
はい、グリッドの getColumnModel メソッドを使用する必要があります。
grid.getColumnModel().setRenderer(2, function(value, metaData, record, rowIndex, colIndex, store) {
return record.get('quantity') + record.get('loss');
});
詳細: http://dev.sencha.com/deploy/ext-3.3.1/docs/?class=Ext.grid.GridPanelおよび
http://dev.sencha.com/deploy/ext-3.3.1/ docs/?class=Ext.grid.ColumnModel?class=Ext.grid.ColumnModel