Get Free Trial
Get Free Trial
  1. API reference
    1. Introduction
    2. Flexmonster()
  2. Objects
    1. All objects
    2. Report Object
    3. Data Source Object
    4. Slice Object
    5. Options Object
    6. Filtering
      1. Filter Object
      2. Number Query Object
      3. String Query Object
      4. Date Query Object
      5. Time Query Object
      6. Value Query Object
    7. Format Object
    8. Conditional Format Object
    9. Cell Data Object
    10. Chart Data Object
    11. Toolbar Object
  3. Methods
    1. All methods
    2. addCalculatedMeasure
    3. addCondition
    4. alert
    5. clear
    6. clearFilter
    7. clearXMLACache
    8. closeFieldsList
    9. collapseAllData
    10. collapseData
    11. connectTo
    12. customizeCell
    13. customizeContextMenu
    14. dispose
    15. expandAllData
    16. expandData
    17. exportTo
    18. getAllConditions
    19. getAllHierarchies
    20. getAllMeasures
    21. getCell
    22. getColumns
    23. getCondition
    24. getFilter
    25. getFormat
    26. getMeasures
    27. getMembers
    28. getOptions
    29. getReport
    30. getReportFilters
    31. getRows
    32. getSelectedCell
    33. getSort
    34. getXMLACatalogs
    35. getXMLACubes
    36. getXMLADataSources
    37. getXMLAProviderName
    38. load
    39. off
    40. on
    41. open
    42. openCalculatedValueEditor
    43. openFieldsList
    44. openFilter
    45. print
    46. refresh
    47. removeAllCalculatedMeasures
    48. removeAllConditions
    49. removeCalculatedMeasure
    50. removeCondition
    51. removeSelection
    52. runQuery
    53. save
    54. setFilter
    55. setFormat
    56. setOptions
    57. setReport
    58. setSort
    59. showCharts
    60. showGrid
    61. showGridAndCharts
    62. sortingMethod
    63. sortValues
    64. updateData
  4. Events
    1. All events
    2. afterchartdraw
    3. aftergriddraw
    4. beforegriddraw
    5. beforetoolbarcreated
    6. cellclick
    7. celldoubleclick
    8. chartclick
    9. datachanged
    10. dataerror
    11. datafilecancelled
    12. dataloaded
    13. exportcomplete
    14. exportstart
    15. fieldslistclose
    16. fieldslistopen
    17. filterclose
    18. filteropen
    19. loadingdata
    20. loadinglocalization
    21. loadingolapstructure
    22. loadingreportfile
    23. localizationerror
    24. localizationloaded
    25. olapstructureerror
    26. olapstructureloaded
    27. openingreportfile
    28. printcomplete
    29. printstart
    30. querycomplete
    31. queryerror
    32. ready
    33. reportchange
    34. reportcomplete
    35. reportfilecancelled
    36. reportfileerror
    37. runningquery
    38. update
Table of contents

Options Object

Options object is used to specify appearance and functionality available for customers. It has the following properties:

  • viewType – String. The type of view to show: "grid" or "charts" or "grid_charts" (starting from v1.9).
  • grid – Object. Contains information about grid:
    • type – String. The selected grid’s type. The following grid types are supported: "compact", "classic", and "flat".
    • title – String. The title of the grid.
    • showFilter – Boolean. Indicates whether column/row filter controls and report filter controls are visible on the grid (true) or not (false). Default value: true.
    • showHeaders – Boolean. Indicates whether the spreadsheet headers are visible (true) or not (false).
    • showTotals – String. Specifies where to show totals: in rows ("rows"), in columns ("columns"), in rows and columns ("on") or not at all ("off"). Default value: "on".
    • showGrandTotals – String. Specifies where to show grand totals: in rows ("rows"), in columns ("columns"), in rows and columns ("on") or not at all ("off"). Default value: "on".
    • grandTotalsPosition – String. Indicates whether the grand totals are displayed at the top of the pivot table ("top") or at the bottom ("bottom"). Only available for the flat view. Default value: "top"
    • showHierarchies – Boolean. Specifies how to show drillable hierarchy cells on the grid: with a link on the right (true) or with an icon on the left (false). Default value: true.
    • showHierarchyCaptions – Boolean. Indicates whether the hierarchy captions are visible (true) on the grid or not (false). Default value: true.
    • drillthroughMaxRows – Number. Sets the maximum number of rows for the SSAS drill-through pop-up window. Default value: 1000.
    • showReportFiltersArea (starting from v2.2) – Boolean. Indicates whether the reports filtering cells on the grid should be visible (true) or not (false). Default value is true.
    • dragging – Boolean. Indicates whether the hierarchies on the grid can be dragged (true) or not (false). Default value: true.
    • showAutoCalculationBar – Boolean. Indicates whether the autoCalculationBar feature is turned on (true) or not (false). Default value: true.
  • chart – Object. Contains information about charts:
    • type – String. The selected chart type. The following chart types are supported: "column", "bar_h", "line", "scatter", "pie", "stacked_column", and "column_line".
    • title – String. The title of the chart.
    • showFilter – Boolean. Indicates whether column/row filter controls and report filter controls are visible on the charts (true) or not (false). Default value: true.
    • multipleMeasures – Boolean. Available from v1.9. Indicates whether to show multiple measures on charts. Default value: false.
    • oneLevel – Boolean. In a drillable chart, defines whether the chart shows all nodes on the x-axis and the legend (false) or only the lowest expanded node on the x-axis and the legend (true). Default value: false.
    • reversedAxes – Boolean. Reverses the columns and rows when drawing charts. Default value: false.
    • autoRange – Boolean. Indicates whether the range of values in the charts is selected automatically or not.
    • showLegend – Boolean. Indicates whether the legend for the charts is visible (true) or not (false). Default value: true.
    • showLegendButton – Boolean. Indicates whether the button to show/hide the legend for the charts is visible. Default value: false which means that the legend is visible, without a button to hide it.
    • showAllLabels – Boolean. Setting this value to true allows showing all the labels in a pie сhart. If the value is false then only the labels that can be shown without overlapping will be shown. Default value: false.
    • showDataLabels – Boolean. Setting this value to true allows showing labels in charts. If the value is false, the labels will be hidden. Use showAllLabels to configure the labels in a pie сhart. Default value: false.
    • showMeasures – Boolean. Hides all dropdowns on the tops of the charts. This is useful if you want to show a simple chart without any controls or if you want to save space. Default value: true – the dropdowns are visible.
    • showOneMeasureSelection – Boolean. Default value: true, which means that the measures dropdown is always visible – regardless of the number of measures in it. If the value is set to false, the measures dropdown on charts will be hidden if there is only one measure in the list and visible if there are two or more measures.
    • showWarning – Boolean. Indicates whether warnings are shown if the data is too big for charts.
    • position – String. The positions of the charts in relation to the grid. It can be "bottom", "top", "left", or "right". Default value: "bottom".
    • activeMeasure – Object. Identifies the selected measure in the charts view. Has the following properties:
      • uniqueName – String. The unique measure name.
      • aggregation – String. The measure aggregation type.
    • pieDataIndex – String. The selected tuple index on the Pie chart.
    • axisShortNumberFormat – Boolean. Indicates whether axes labels on charts are displayed in short number format like 10K, 10M, 10B, 10T (true) or not (false). Default value: undefined (show short format if max value > 10M).
  • filter – Object. Filtering options:
    • timezoneOffset – Number. The difference (in minutes) between UTC and user’s local time zone. Used to adjust the dates in the filter. Default value: user’s local time.
    • weekOffset – Number. Sets amount of days to be added to the start of the week (Sunday). Used to adjust the first day of the week in the filter’s calendar. Default value: 1 (Monday is the first day of the week).
    • dateFormat – String. Date pattern to format dates in filter’s date inputs. Has two possible values: "dd/MM/yyyy" and "MM/dd/yyyy". Default value: "dd/MM/yyyy".
    • liveSearch – Boolean. Indicates whether the search in the filter pop-up window is performed while the user types (true) or requires the Enter button to start searching (false). Default value: true.
  • configuratorActive – Boolean. Indicates whether the Field List is opened (true) or closed (false). Default value: false.
  • configuratorButton – Boolean. Indicates whether the Field List toggle button is visible (true) or not (false).
  • showAggregations – Boolean. Indicates whether the aggregation selection control is visible (true) or not (false) for measures on the Field List. Default value: true.
  • showCalculatedValuesButton – Boolean. Controls the visibility of “Add calculated value” in the Field List. Default value: true.
  • grouping – Boolean. Indicates whether grouping is enabled. Default value: false. This feature allows customers to group chosen elements using a filter window. For example, if the customer has shops in different cities and wants to analyze sales information, it would be possible to combine several cities in one group by geography, by sales numbers, etc. Only available for "ocsv", "csv", and "json" data source types.
  • editing – Boolean. Indicates whether the editing feature is enabled (true) or disabled (false) on the drill-through pop-up window for CSV, OCSV, and JSON data sources. The user will be able to double-click the cell and enter a new value into it if the editing feature is enabled.
  • drillThrough – Boolean. Indicates whether the drill-through feature is enabled (true) or disabled (false). The user can drill through by double-clicking the cell with a value. Default value: true.
  • showDrillThroughConfigurator – Boolean. Indicates whether the Field List toggle button is visible in the drill-through view. Default value: true. Only for "ocsv", "csv", and "json" data sources.
  • sorting – String. Indicates whether the sorting controls are visible in rows ("rows"), in columns ("columns"), in rows and columns ("on" or true) on the grid cells, or not visible at all ("off" or false). Default value: "on".
  • datePattern – String. Used to format “date string” date fields ("type": "date string" in JSON, "ds+" prefix in CSV). The default pattern string is "dd/MM/yyyy".
  • dateTimePattern – String. Used to format “datetime” date fields ("type": "datetime" in JSON, "dt+" prefix in CSV). The default pattern string is "dd/MM/yyyy HH:mm:ss".
  • timePattern – String. Used to format “time” date fields ("type": "time" in JSON, "t+" prefix in CSV). The default pattern string is "HH:mm:ss".
  • dateTimezoneOffset – Number. It allows setting the timezone for hierarchical dates (for JSON: "date", "year/month/day" and "year/quarter/month/day"; for CSV: "d+", "D+" and "D4+"). See an example.
  • defaultDateType – String. Used to specify which data types should be applied to date fields by default ("date", "date string", "year/month/day", "year/quarter/month/day" or "datetime") for CSV and JSON data sources.
  • saveAllFormats – Boolean. If there are more than 5 formats defined, only the formats that are used for "active: true" measures will be saved in the report. In order to save all the formats, set the saveAllFormats property to true. Default value: false.
  • showDefaultSlice – Boolean. Defines whether the component selects a default slice for a report with an empty slice (when nothing is set in rows, columns, report filters, and measures). If true, the first hierarchy from data goes to rows and the first measure goes to columns in the default slice. To avoid this default behavior, set this property to false. Default value: true. Only available for "csv", "ocsv", and "json" data source types.
  • useOlapFormatting  – Boolean. Indicates whether the values from data source will be formatted according to the format defined in the cube (true) or not (false). Default value: false.
  • showMemberProperties – Boolean. Indicates whether the member properties for an OLAP data source are available in the component (true) or not (false). Default value: false. This feature is only for "microsoft analysis services" and "mondrian" data source types.
  • showEmptyData – Boolean. By default, if you have an empty CSV data source but the header is defined the component will show your slice with empty data cells. If you set this value to false – the component will show a message instead: “Data source is empty. Please check the CSV file.”
  • defaultHierarchySortName – String. The sorting type for hierarchies’ members ("asc", "desc", or "unsorted"). Default value: "asc".
  • showOutdatedDataAlert – Boolean. Setting this value to true will show a warning to the user before automatic reloading of data from the cube. Default value: false which means there will be no warnings. Only for Flexmonster Accelerator.
  • showAggregationLabels – Boolean. Indicates whether aggregation labels like "Total Sum of", "Sum of", etc. are shown in the column/row titles. Default value: true.
  • showAllFieldsDrillThrough – Boolean. Indicates whether prefiltering the drill-through view columns is enabled (false) or the drill-through view displays all the available columns (true) when using SSAS with Flexmonster Accelerator. Default value: false.
  • strictDataTypes – Boolean. Allows increasing data analyzing speed. Only for "json" data source type. Setting strictDataTypes to true will make the component treat numeric values (or any other marked as a measure) only as measures and won’t allow using them as hierarchies. To enable this feature, add isMeasure: true to the necessary numeric fields (check out an example). Default value: false.
  • showFieldListSearch – Boolean. Indicates whether the search bar in the Field List is shown (true) or hidden (false). When the search bar is hidden, it will be shown only in case the number of the hierarchies exceeds 50 (40 for the flat form). Default value: false.
  • simplifyFieldListFolders – Boolean. Indicates whether the folders containing one field should show this field in the root (true) or not (false). Only for Elasticsearch and SSAS data sources. Default value: false.
  • validateFormulas – Boolean. Indicates whether the validation is performed for calculated values (true) or not (false). In case the validation is turned on and the report contains invalid formula, the “Wrong formula format” alert message is shown. To turn off the “Wrong formula format” alert message, set the validateFormulas property to false. Default value: true.
  • validateReportFiles – Boolean. Indicates whether validation of report files is turned on (true) or turned off (false). Setting this value to false allows loading report files in the old format without an error message. Should be used in global options. Default value: true.
  • caseSensitiveMembers – Boolean. Indicates whether the hierarchies’ members are case-sensitive (true) or not (false). Default value: false.
  • fieldListPosition – String. Indicates whether the Field List is always shown on the right ("right") or in the pop-up window (undefined). Default value: undefined.
  • liveFiltering – Boolean. Indicates whether the live filtering for hierarchies’ members is enabled (true) or disabled (false). Default value: false.

Get Options Object via getOptions() API call. Set this object via setOptions().

More information about options is available in article about Options Object.