Sencha Documentation

The PivotGrid component enables rapid summarization of large data sets. It provides a way to reduce a large set of data down into a format where trends and insights become more apparent. A classic example is in sales data; a company will often have a record of all sales it makes for a given period - this will often encompass thousands of rows of data. The PivotGrid allows you to see how well each salesperson performed, which cities generate the most revenue, how products perform between cities and so on.

A PivotGrid is composed of two axes (left and top), one measure and one aggregation function. Each axis can contain one or more dimension, which are ordered into a hierarchy. Dimensions on the left axis can also specify a width. Each dimension in each axis can specify its sort ordering, defaulting to "ASC", and must specify one of the fields in the Record used by the PivotGrid's Store.

// This is the record representing a single sale
var SaleRecord = Ext.data.Record.create([
    {name: 'person',   type: 'string'},
    {name: 'product',  type: 'string'},
    {name: 'city',     type: 'string'},
    {name: 'state',    type: 'string'},
    {name: 'year',     type: 'int'},
    {name: 'value',    type: 'int'}
]);

// A simple store that loads SaleRecord data from a url
var myStore = new Ext.data.Store({
    url: 'data.json',
    autoLoad: true,
    reader: new Ext.data.JsonReader({
        root: 'rows',
        idProperty: 'id'
    }, SaleRecord)
});

// Create the PivotGrid itself, referencing the store
var pivot = new Ext.grid.PivotGrid({
    store     : myStore,
    aggregator: 'sum',
    measure   : 'value',

    leftAxis: [
        {
            width: 60,
            dataIndex: 'product'
        },
        {
            width: 120,
            dataIndex: 'person',
            direction: 'DESC'
        }
    ],

    topAxis: [
        {
            dataIndex: 'year'
        }
    ]
});

The specified measure is the field from SaleRecord that is extracted from each combination of product and person (on the left axis) and year on the top axis. There may be several SaleRecords in the data set that share this combination, so an array of measure fields is produced. This array is then aggregated using the aggregator function.

The default aggregator function is sum, which simply adds up all of the extracted measure values. Other built-in aggregator functions are count, avg, min and max. In addition, you can specify your own function. In this example we show the code used to sum the measures, but you can return any value you like. See aggregator for more details.

new Ext.grid.PivotGrid({
    aggregator: function(records, measure) {
        var length = records.length,
            total  = 0,
            i;

        for (i = 0; i < length; i++) {
            total += records[i].get(measure);
        }

        return total;
    },
    
    renderer: function(value) {
        return Math.round(value);
    },
    
    //your normal config here
});

Renderers

PivotGrid optionally accepts a renderer function which can modify the data in each cell before it is rendered. The renderer is passed the value that would usually be placed in the cell and is expected to return the new value. For example let's imagine we had height data expressed as a decimal - here's how we might use a renderer to display the data in feet and inches notation:

new Ext.grid.PivotGrid({
    //in each case the value is a decimal number of feet
    renderer  : function(value) {
        var feet   = Math.floor(value),
            inches = Math.round((value - feet) * 12);

        return Ext.util.Format.format("{0}' {1}\"", feet, inches);
    },
    //normal config here
});

Reconfiguring

All aspects PivotGrid's configuration can be updated at runtime. It is easy to change the measure, aggregation function, left and top axes and refresh the grid.

In this case we reconfigure the PivotGrid to have city and year as the top axis dimensions, rendering the average sale value into the cells:

//the left axis can also be changed
pivot.topAxis.setDimensions([
    {dataIndex: 'city', direction: 'DESC'},
    {dataIndex: 'year', direction: 'ASC'}
]);

pivot.setMeasure('value');
pivot.setAggregator('avg');

pivot.view.refresh(true);

See the PivotAxis documentation for further detail on reconfiguring axes.

Config Options

 
aggregator : String|Function
The aggregation function to use to combine the measures extracted for each dimension combination. Can be any of the b...
The aggregation function to use to combine the measures extracted for each dimension combination. Can be any of the built-in aggregators (sum, count, avg, min, max). Can also be a function which accepts two arguments (an array of Records to aggregate, and the measure to aggregate them on) and should return a String.
 
animCollapse : Boolean
true to animate the transition when the panel is collapsed, false to skip the animation (defaults to true if the Ext....
true to animate the transition when the panel is collapsed, false to skip the animation (defaults to true if the Ext.Fx class is available, otherwise false). May also be specified as the animation duration in milliseconds.
 
The id of a column in this grid that should expand to fill unused space. This value specified here can not be 0. Note...

The id of a column in this grid that should expand to fill unused space. This value specified here can not be 0.


Note: If the Grid's view is configured with forceFit=true the autoExpandColumn is ignored. See Ext.grid.Column.width for additional details.

See autoExpandMax and autoExpandMin also.

 
autoExpandMax : Number
The maximum width the autoExpandColumn can have (if enabled). Defaults to 1000.
The maximum width the autoExpandColumn can have (if enabled). Defaults to 1000.
 
autoExpandMin : Number
The minimum width the autoExpandColumn can have (if enabled). Defaults to 50.
The minimum width the autoExpandColumn can have (if enabled). Defaults to 50.
 
baseCls : String
The base CSS class to apply to this panel's element (defaults to 'x-panel').
The base CSS class to apply to this panel's element (defaults to 'x-panel').
 
bodyBorder : Number/Boolean
A shortcut for setting a border style on the body element. The value can either be a number to be applied to all side...
A shortcut for setting a border style on the body element. The value can either be a number to be applied to all sides, or a normal css string describing borders. Defaults to undefined.
 
bodyMargin : Number/Boolean
A shortcut for setting a margin style on the body element. The value can either be a number to be applied to all side...
A shortcut for setting a margin style on the body element. The value can either be a number to be applied to all sides, or a normal css string describing margins. Defaults to undefined.
 
bodyPadding : Number/Boolean
A shortcut for setting a padding style on the body element. The value can either be a number to be applied to all sid...
A shortcut for setting a padding style on the body element. The value can either be a number to be applied to all sides, or a normal css string describing padding. Defaults to undefined.
 
bubbleEvents : Array
An array of events that, when fired, should be bubbled to any parent container. See Ext.util.Observable.enableBubble....

An array of events that, when fired, should be bubbled to any parent container. See Ext.util.Observable.enableBubble. Defaults to [].

 
closable : Boolean
True to display the 'close' tool button and allow the user to close the window, false to hide the button and disallow...

True to display the 'close' tool button and allow the user to close the window, false to hide the button and disallow closing the window (defaults to false).

By default, when close is requested by clicking the close button in the header, the close method will be called. This will destroy the Panel and its content meaning that it may not be reused.

To make closing a Panel hide the Panel so that it may be reused, set closeAction to 'hide'.

 
closeAction : String
The action to take when the close header tool is clicked: <div class="mdetail-params"> 'close' : Default<div class="s...

The action to take when the close header tool is clicked:

  • 'close' : Default
    remove the window from the DOM and destroy it and all descendant Components. The window will not be available to be redisplayed via the show method.
  • 'hide' :
    hide the window by setting visibility to hidden and applying negative offsets. The window will be available to be redisplayed via the show method.

Note: This behavior has changed! setting *does* affect the close method which will invoke the approriate closeAction.

 
cm : Object
Shorthand for colModel.
Shorthand for colModel.
 
colModel : Object
The Ext.grid.ColumnModel to use when rendering the grid (required).
The Ext.grid.ColumnModel to use when rendering the grid (required).
 
The direction to collapse the Panel when the toggle button is clicked. Defaults to the headerPosition Important: This...

The direction to collapse the Panel when the toggle button is clicked.

Defaults to the headerPosition

Important: This config is ignored for collapsible Panels which are direct child items of a border layout.

Specify as 'top', 'bottom', 'left' or 'right'.

 
collapseFirst : Boolean
true to make sure the collapse/expand toggle button always renders first (to the left of) any other tools in the pane...
true to make sure the collapse/expand toggle button always renders first (to the left of) any other tools in the panel's title bar, false to render it last (defaults to true).
 
collapseMode : String
Important: this config is only effective for collapsible Panels which are direct child items of a border layout. When...

Important: this config is only effective for collapsible Panels which are direct child items of a border layout.

When not a direct child item of a border layout, then the Panel's header remains visible, and the body is collapsed to zero dimensions. If the Panel has no header, then a new header (orientated correctly depending on the collapseDirection) will be inserted to show a the title and a re-expand tool.

When a child item of a border layout, this config has two options:

  • alt : Default.
    When collapsed, a placeholder Container is injected into the layout to represent the Panel and to provide a UI with a Tool to allow the user to re-expand the Panel.
  • header :
    The Panel collapses to leave a header visible as when not inside a border layout.

 
collapsed : Boolean
true to render the panel collapsed, false to render it expanded (defaults to false).
true to render the panel collapsed, false to render it expanded (defaults to false).
 
collapsedCls : String
A CSS class to add to the panel's element after it has been collapsed (defaults to 'x-panel-collapsed').
A CSS class to add to the panel's element after it has been collapsed (defaults to 'x-panel-collapsed').
 
collapsible : Boolean
True to make the panel collapsible and have an expand/collapse toggle Tool added into the header tool button area. Fa...

True to make the panel collapsible and have an expand/collapse toggle Tool added into the header tool button area. False to keep the panel sized either statically, or by an owning layout manager, with no toggle Tool (defaults to false).

See collapseMode and collapseDirection
 
columnLines : Boolean
true to add css for column separation lines. Default is false.
true to add css for column separation lines. Default is false.
 
columns : Array
An array of columns to auto create a Ext.grid.ColumnModel. The ColumnModel may be explicitly created via the colMode...
An array of columns to auto create a Ext.grid.ColumnModel. The ColumnModel may be explicitly created via the colModel configuration property.
 
ddGroup : String
The DD group this GridPanel belongs to. Defaults to 'GridDD' if not specified.
The DD group this GridPanel belongs to. Defaults to 'GridDD' if not specified.
 
ddText : String
Configures the text in the drag proxy. Defaults to: ddText : '{0} selected row{1}' {0} is replaced with the number o...
Configures the text in the drag proxy. Defaults to:
ddText : '{0} selected row{1}'
{0} is replaced with the number of selected rows.
 
deferRowRender : Boolean
Defaults to true to enable deferred row rendering. This allows the GridPanel to be initially rendered empty, with the...

Defaults to true to enable deferred row rendering.

This allows the GridPanel to be initially rendered empty, with the expensive update of the row structure deferred so that layouts with GridPanels appear more quickly.

 
true to disable selections in the grid. Defaults to false. This configuration will lock the selection model that the ...

true to disable selections in the grid. Defaults to false. This configuration will lock the selection model that the GridPanel uses.

 
dockedItems : Object/Array
A component or series of components to be added as docked items to this panel. The docked items can be docked to eith...
A component or series of components to be added as docked items to this panel. The docked items can be docked to either the top, right, left or bottom of a panel. This is typically used for things like toolbars or tab bars:
var panel = new Ext.Panel({
    fullscreen: true,
    dockedItems: [{
        xtype: 'toolbar',
        dock: 'top',
        items: [{
            text: 'Docked to the bottom'
        }]
    }]
});
 
Defaults to true to enable hiding of columns with the header menu.
Defaults to true to enable hiding of columns with the header menu.
 
Defaults to true to enable drag and drop reorder of columns. false to turn off column reordering via drag drop.
Defaults to true to enable drag and drop reorder of columns. false to turn off column reordering via drag drop.
 
false to turn off column resizing for the whole grid. Defaults to true.
false to turn off column resizing for the whole grid. Defaults to true.
 
enableDragDrop : Boolean
Enables dragging of the selected rows of the GridPanel. Defaults to false. Setting this to true causes this GridPanel...

Enables dragging of the selected rows of the GridPanel. Defaults to false.

Setting this to true causes this GridPanel's GridView to create an instance of Ext.grid.GridDragZone. Note: this is available only after the Grid has been rendered as the GridView's dragZone property.

A cooperating DropZone must be created who's implementations of onNodeEnter, onNodeOver, onNodeOut and onNodeDrop are able to process the data which is provided.

 
enableHdMenu : Boolean
Defaults to true to enable the drop down button for menu in the headers.
Defaults to true to enable the drop down button for menu in the headers.
 
enableKeyNav : Boolean
Turns on/off keyboard navigation within the grid. Defaults to true.
Turns on/off keyboard navigation within the grid. Defaults to true.
 
floatable : Boolean
Important: This config is only effective for collapsible Panels which are direct child items of a border layout. true...

Important: This config is only effective for collapsible Panels which are direct child items of a border layout.

true to allow clicking a collapsed Panel's placeHolder to display the Panel floated above the layout, false to force the user to fully expand a collapsed region by clicking the expand button to see it again (defaults to true).
 
frame : Boolean
True to apply a frame to the panel.
True to apply a frame to the panel.
 
Specify as 'top', 'bottom', 'left' or 'right'. Defaults to 'top'.
Specify as 'top', 'bottom', 'left' or 'right'. Defaults to 'top'.
 
true to hide the expand/collapse toggle button when collapsible == true, false to display it (defaults to false).
true to hide the expand/collapse toggle button when collapsible == true, false to display it (defaults to false).
 
hideHeaders : Boolean
True to hide the grid's header. Defaults to false.
True to hide the grid's header. Defaults to false.
 
leftAxis : Array|Ext.grid.PivotAxis
Either and array of dimension to use on the left axis, or a Ext.grid.PivotAxis instance. If an array is passed, it is...
Either and array of dimension to use on the left axis, or a Ext.grid.PivotAxis instance. If an array is passed, it is turned into a PivotAxis internally.
 
loadMask : Object
An Ext.LoadMask config or true to mask the grid while loading. Defaults to false.
An Ext.LoadMask config or true to mask the grid while loading. Defaults to false.
 
maxHeight : Number
Sets the maximum height of the grid - ignored if autoHeight is not on.
Sets the maximum height of the grid - ignored if autoHeight is not on.
 
measure : String
The field to extract from each Record when pivoting around the two axes. See the class introduction docs for usage
The field to extract from each Record when pivoting around the two axes. See the class introduction docs for usage
 
Minimum width of all form buttons in pixels (defaults to 75). If set, this will be used as the default value for the ...
Minimum width of all form buttons in pixels (defaults to 75). If set, this will be used as the default value for the Ext.form.Button.minWidth config of each Button added to the footer toolbar. Will be ignored for buttons that have this value configured some other way, e.g. in their own config object or via the defaults config of their parent container.
 
The minimum width a column can be resized to. Defaults to 25.
The minimum width a column can be resized to. Defaults to 25.
 
placeHolder : Mixed
Important: This config is only effective for collapsible Panels which are direct child items of a border layout when ...

Important: This config is only effective for collapsible Panels which are direct child items of a border layout when using the default 'alt' collapseMode.

b>Optional. A Component (or config object for a Component) to show in place of this Panel when this Panel is collapsed by a border layout. Defaults to a generated Header containing a Tool to re-expand the Panel.

 
preventHeader : Boolean
Prevent a Header from being created and shown. Defaults to false.
Prevent a Header from being created and shown. Defaults to false.
 
renderer : Function
Optional renderer to pass values through before they are rendered to the dom. This gives an opportunity to modify cel...
Optional renderer to pass values through before they are rendered to the dom. This gives an opportunity to modify cell contents after the value has been computed.
 
scroll : String/Boolean
Valid values are 'both', 'horizontal' or 'vertical'. true implies 'both'. false implies 'none'. Defaults to true.
Valid values are 'both', 'horizontal' or 'vertical'. true implies 'both'. false implies 'none'. Defaults to true.
 
selModel : Mixed
 
sm : Object
Shorthand for selModel.
Shorthand for selModel.
 
stateEvents : Array
An array of events that, when fired, should trigger this component to save its state. Defaults to:stateEvents: ['colu...
An array of events that, when fired, should trigger this component to save its state. Defaults to:
stateEvents: ['columnmove', 'columnresize', 'sortchange', 'groupchange']

These can be any types of events supported by this component, including browser or custom events (e.g., ['click', 'customerchange']).

See Ext.Component.stateful for an explanation of saving and restoring Component state.

 
store : Mixed
 
stripeRows : Boolean
true to stripe the rows. Default is false. This causes the CSS class x-grid3-row-alt to be added to alternate rows of...
true to stripe the rows. Default is false.

This causes the CSS class x-grid3-row-alt to be added to alternate rows of the grid. A default CSS rule is provided which sets a background colour, but you can override this with a rule which either overrides the background-color style using the '!important' modifier, or which uses a CSS selector of higher specificity.

 
titleCollapse : Boolean
true to allow expanding and collapsing the panel (when collapsible = true) by clicking anywhere in the header bar, fa...
true to allow expanding and collapsing the panel (when collapsible = true) by clicking anywhere in the header bar, false) to allow it only by clicking to tool button (defaults to false)).
 
topAxis : Array|Ext.grid.PivotAxis
Either and array of dimension to use on the top axis, or a Ext.grid.PivotAxis instance. If an array is passed, it is ...
Either and array of dimension to use on the top axis, or a Ext.grid.PivotAxis instance. If an array is passed, it is turned into a PivotAxis internally.
 
trackMouseOver : Boolean
True to highlight rows when the mouse is over. Default is true for GridPanel, but false for EditorGridPanel.
True to highlight rows when the mouse is over. Default is true for GridPanel, but false for EditorGridPanel.
 
view : Object
The Ext.grid.GridView used by the grid. This can be set before a call to render().
The Ext.grid.GridView used by the grid. This can be set before a call to render().
 
viewConfig : Object
A config object that will be applied to the grid's UI view. Any of the config options available for Ext.grid.GridVie...
A config object that will be applied to the grid's UI view. Any of the config options available for Ext.grid.GridView can be specified here. This option is ignored if view is specified.

Properties

 
dd : Ext.dd.DragSource.
If this Panel is configured draggable, this property will contain an instance of Ext.dd.DragSource which handles drag...

If this Panel is configured draggable, this property will contain an instance of Ext.dd.DragSource which handles dragging the Panel.

The developer must provide implementations of the abstract methods of Ext.dd.DragSource in order to supply behaviour for each stage of the drag/drop process. See draggable.
 
leftAxis : Ext.grid.PivotAxis
The configured Ext.grid.PivotAxis used as the left Axis for this Pivot Grid
The configured Ext.grid.PivotAxis used as the left Axis for this Pivot Grid
 
topAxis : Ext.grid.PivotAxis
The configured Ext.grid.PivotAxis used as the top Axis for this Pivot Grid
The configured Ext.grid.PivotAxis used as the top Axis for this Pivot Grid

Methods

 
addDocked( Object/Array component., [Number pos] ) : Void
Adds docked item(s) to the panel.
Adds docked item(s) to the panel.

Parameters

  • component. : Object/Array
    The Component or array of components to add. The components must include a 'dock' parameter on each component to indicate where it should be docked ('top', 'right', 'bottom', 'left').
  • pos : Number
    (optional) The index at which the Component will be added

Returns

  • Void
 
close : Void
Closes the Panel. By default, this method, removes it from the DOM, destroys the Panel object and all its descendant ...

Closes the Panel. By default, this method, removes it from the DOM, destroys the Panel object and all its descendant Components. The beforeclose event is fired before the close happens and will cancel the close action if it returns false.

Note: This method is not affected by the closeAction setting which only affects the action triggered when clicking the 'close' tool in the header. To hide the Panel without destroying it, call hide.

 
collapse( Number direction., Boolean animate ) : Ext.panel.Panel
Collapses the panel body so that the body becomes hidden. Docked Components parallel to the border towards which the ...
Collapses the panel body so that the body becomes hidden. Docked Components parallel to the border towards which the collapse takes place will remain visible. Fires the beforecollapse event which will cancel the collapse action if it returns false.

Parameters

  • direction. : Number
    The direction to collapse towards. Must be one of
    • Ext.Component.DIRECTION_TOP
    • Ext.Component.DIRECTION_RIGHT
    • Ext.Component.DIRECTION_BOTTOM
    • Ext.Component.DIRECTION_LEFT
  • animate : Boolean
    True to animate the transition, else false (defaults to the value of the animCollapse panel config)

Returns

  • Ext.panel.Panel   this
 
expand( Boolean animate ) : Ext.panel.Panel
Expands the panel body so that it becomes visible. Fires the beforeexpand event which will cancel the expand action ...
Expands the panel body so that it becomes visible. Fires the beforeexpand event which will cancel the expand action if it returns false.

Parameters

  • animate : Boolean
    True to animate the transition, else false (defaults to the value of the animCollapse panel config)

Returns

  • Ext.panel.Panel   this
 
getAggregator : Function
Returns the function currently used to aggregate the records in each Pivot cell
Returns the function currently used to aggregate the records in each Pivot cell
 
getComponent( String/Number comp ) : Ext.Component
Attempts a default component lookup (see Ext.container.Container.getComponent). If the component is not found in the ...
Attempts a default component lookup (see Ext.container.Container.getComponent). If the component is not found in the normal items, the dockedItems are searched and the matched component (if any) returned (see {@loink #getDockedComponent}). Note that docked items will only be matched by component id or itemId -- if you pass a numeric index only non-docked child components will be searched.

Parameters

  • comp : String/Number
    The component id, itemId or position to find

Returns

  • Ext.Component   The component (if found)
 
getDockedComponent( String/Number comp ) : Ext.Component
Finds a docked component by id, itemId or position
Finds a docked component by id, itemId or position

Parameters

  • comp : String/Number
    The id, itemId or position of the docked component (see getComponent for details)

Returns

  • Ext.Component   The docked component (if found)
 
Retrieve an array of all currently docked components.
Retrieve an array of all currently docked components.
 
Called to get grid's drag proxy text, by default returns this.ddText.
Called to get grid's drag proxy text, by default returns this.ddText.
 
getSelectionModel : SelectionModel
Returns the grid's selection model configured by the selModel configuration option. If no selection model was configu...
Returns the grid's selection model configured by the selModel configuration option. If no selection model was configured, this will create and return a RowSelectionModel.
 
getView : Ext.grid.PivotGridView
Returns the grid's GridView object.
Returns the grid's GridView object.
 
insertDocked( Number pos, Object/Array component. ) : Void
Inserts docked item(s) to the panel at the indicated position.
Inserts docked item(s) to the panel at the indicated position.

Parameters

  • pos : Number
    The index at which the Component will be inserted
  • component. : Object/Array
    The Component or array of components to add. The components must include a 'dock' paramater on each component to indicate where it should be docked ('top', 'right', 'bottom', 'left').

Returns

  • Void
 
reconfigure( Ext.data.Store store, Ext.grid.ColumnModel colModel ) : Void
Reconfigures the grid to use a different Store and Column Model and fires the 'reconfigure' event. The View will be b...

Reconfigures the grid to use a different Store and Column Model and fires the 'reconfigure' event. The View will be bound to the new objects and refreshed.

Be aware that upon reconfiguring a GridPanel, certain existing settings may become invalidated. For example the configured autoExpandColumn may no longer exist in the new ColumnModel. Also, an existing PagingToolbar will still be bound to the old Store, and will need rebinding. Any plugins might also need reconfiguring with the new data.

Parameters

Returns

  • Void
 
removeDocked( Ext.Component item., [Boolean autoDestroy] ) : Void
Removes the docked item from the panel.
Removes the docked item from the panel.

Parameters

  • item. : Ext.Component
    The Component to remove.
  • autoDestroy : Boolean
    (optional) Destroy the component after removal.

Returns

  • Void
 
setAggregator( String|Function aggregator ) : Void
Sets the function to use when aggregating data for each cell.
Sets the function to use when aggregating data for each cell.

Parameters

  • aggregator : String|Function
    The new aggregator function or named function string

Returns

  • Void
 
setIconClass( cls undefined ) : Void
Set the iconCls for the panel's header. See Ext.panel.Header.iconCls.
Set the iconCls for the panel's header. See Ext.panel.Header.iconCls.

Parameters

  • undefined : cls

Returns

  • Void
 
setLeftAxis( Ext.grid.PivotAxis axis, Boolean refresh ) : Void
Sets the left axis of this pivot grid. Optionally refreshes the grid afterwards.
Sets the left axis of this pivot grid. Optionally refreshes the grid afterwards.

Parameters

  • axis : Ext.grid.PivotAxis
    The pivot axis
  • refresh : Boolean
    True to immediately refresh the grid and its axes (defaults to false)

Returns

  • Void
 
setMeasure( String measure ) : Void
Sets the field name to use as the Measure in this Pivot Grid
Sets the field name to use as the Measure in this Pivot Grid

Parameters

  • measure : String
    The field to make the measure

Returns

  • Void
 
setTitle( String title ) : Void
Set a title for the panel's header. See Ext.panel.Header.title.
Set a title for the panel's header. See Ext.panel.Header.title.

Parameters

  • title : String

Returns

  • Void
 
setTopAxis( Ext.grid.PivotAxis axis, Boolean refresh ) : Void
Sets the top axis of this pivot grid. Optionally refreshes the grid afterwards.
Sets the top axis of this pivot grid. Optionally refreshes the grid afterwards.

Parameters

  • axis : Ext.grid.PivotAxis
    The pivot axis
  • refresh : Boolean
    True to immediately refresh the grid and its axes (defaults to false)

Returns

  • Void
 
toggleCollapse : Ext.panel.Panel
Shortcut for performing an expand or collapse based on the current state of the panel.
Shortcut for performing an expand or collapse based on the current state of the panel.

Events

 
bodyresize( Ext.Panel p, Number width, Number height )
Fires after the Panel has been resized.
Fires after the Panel has been resized.

Parameters

  • p : Ext.Panel
    the Panel which has been resized.
  • width : Number
    The Panel body's new width.
  • height : Number
    The Panel body's new height.

Returns

  • Void