IMPORTANT

These features are applicable only for the relational data source.

Collapse by default

13 Feb 20192 minutes to read

Allows you to collapse all members displayed in the grid. You can enable collapsing all members by default in the pivot grid by setting the enableCollapseByDefault property to true.

  • JS
  • $(function() {
            $("#PivotGrid1").ejPivotGrid({
                //..
                enableCollapseByDefault:true
            });
        });

    Collapse by default layout in JavaScript pivot grid control

    Collapsed members

    Allows you to collapse the specified members in each field of the pivot grid control. You can collapse desired members in the pivot grid by setting the collapsedMembers.

  • JS
  • $(function() {
            $("#PivotGrid1").ejPivotGrid({
                //..
                rows: [
                        {
                          fieldName: "Country",
                          fieldCaption: "Country"
                        },
                        {
                          fieldName: "State",
                          fieldCaption: "State"
                        }
                    ]
                    //..
                collapsedMembers: { Country: ["Canada", "France"] }
            });
        });

    JavaScript pivot grid control collapsed with specified members