Table of contents

getColumns

getColumns():Array

[starting from version: 1.4]

Returns a list of hierarchies selected in the report slice for columns.

Returns

Array of objects. Each object in array contains the following properties:

  • caption – String. Hierarchy caption.
  • uniqueName – String. Unique hierarchy name.
  • sort – String. Sorting type ("asc" or "desc").
  • type – String. Hierarchy type. The following types are supported: "string", "number", "date", "date string", "year/month/day", "year/quarter/month/day", "datetime", "time", "level".

If data load is in progress an empty array is returned.

Example

flexmonster.getColumns();

/* method returns array of objects
[
{caption: "Business Type", uniqueName: "Business Type", sort: "desc", type: "string"},
{caption: "Category", uniqueName: "Category", sort: "asc", type: "string"}
]
*/

Check out on JSFiddle.

See also

getAllHierarchies
getRows
getReportFilters
getAllMeasures
getMeasures