This event will be triggered at the beginning of every viewer action, including connection, layout and dashboard rendering, popup opening and closing, refreshing, filtering, exporting, and more.
Name | Type | Access | Description |
---|---|---|---|
eventType | get | Will hold the current event type that triggered the event | |
source | get | This will contain the data related to the current event as like below. 1. data 2. element |
|
source.element | object | get | Holds the current event site UI element. If there involves no UI element will be returned as null |
source.data | object | get | Holds the current event data. |
Example
var dashboard = BoldBI.create({
actionBegin: function (args) {
// Write a code block to perform an operation on beginning of every viewer actions
}
});
dashboard.loadDashboard();
Event Types | Description |
---|---|
renderLayout | This event will trigger when the layout of the dashboard started to render. |
renderDashboard | This event will trigger when the dashboard started to render. |
renderWidget | This event will trigger when the widget started to render. |
resizeDashboard | This event will trigger when we invoke the resize dashboard method or when you resize the browser window. |
exportDialogOpen | This event will trigger when the export dialog box opens, when you click on the export option in the context menu. |
exportDialogClose | This event will trigger when the export dialog box closes. |
maximizeDialogOpen | This event will trigger when the Maximize dialog box opens, when you click on the Maximize icon in the widget header. |
maximizeDialogClose | This event will trigger when the Maximize dialog closes. |
filterOverViewOpen | This event will trigger when the filter overview drop-down opens. |
filterOverViewClose | This event will trigger when the filter overview drop-down closes. |
clearFilter | This event will trigger when you clear the individual filter in the filter overview. |
clearAllFilter | This event will trigger when you clear all the filters in the filter overview drop-down. |
clearWidgetFilter | This event will trigger when you clear the filter in the widget. |
exporting | This event will trigger when the dashboard exporting gets started. |
datasourceConfiguration | This event will trigger when the datasource icon is clicked. |
This event will be triggered once all viewer actions have been completed.
Name | Type | Access | Description |
---|---|---|---|
eventType | get | Will hold the current event type that triggered the event | |
source | get | This will contain the data related to the current event as below. 1. element 2. data |
|
source.element | object | get | Holds the current event site UI element. If there involves no UI element will be returned as null |
source.data | object | get | Holds the current event data. |
Example
var dashboard = BoldBI.create({
actionComplete: function (args) {
// Write a code block to perform an operation on every viewer action which completes
}
});
dashboard.loadDashboard();
Event Types | Description |
---|---|
layoutRendered | This event will trigger after the layout rendering is completed. |
dashboardRendered | This event will trigger after the dashboard rendering is completed. |
viewDataDialogOpen | This event will trigger when the ViewData dialog box opens, when you click on the ViewData option in the context menu. |
viewDataDialogClose | This event will trigger when the ViewData dialog box closes. |
exporting | This event will trigger when the dashboard exporting gets started. |
exportCompleted | This event will trigger when the dashboard exporting gets completed. |
clearFilter | This event will trigger when you clear the individual filter in the filter overview and gets completed. |
clearWidgetFilter | This event will trigger when you clear the filter in the widget and gets completed. |
Save | This event will trigger once the Publish option is clicked in dashboard designer mode. |
SaveAs | This event will trigger once the Publish As option is clicked in dashboard designer mode. |
This event is used to customize headers in the AJAX call before sending them to the designer service.
Name | Type | Description |
---|---|---|
args.headers | array[] | Able to add new payload header. |
args.serviceAuthorizationToken | string | Holds the service AuthorizationToken value |
actionType | string | Holds action type of the ajax call. |
Example
var dashboard = BoldBI.create({
ajaxBeforeLoad: function (args) {
// Write a code block to add a new payload header.
// var header = { Key : 'UserId', Value : '1005'};
// args.headers.push(header);
}
});
dashboard.loadDashboard();
This event will be triggered before the dashboard context menu is rendered.
Name | Type | Access | Description |
---|---|---|---|
type | get | Will holds the current event type that triggered the event | |
model | get | Holds the dashboard viewer's object. | |
dashboardPath | string | get | Holds the current dashboard path value. |
iconsinformation | array | set | Holds the information about the list of icons to be rendered in the dashboard. |
enableComment | boolean | get | Holds the enableComment value. |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
beforeContextMenuRender: function (args) {
// Write a code block to perform an operation before the dashboard context menu is rendered
}
});
dashboard.loadDashboard();
This event will be triggered after the more options icon is clicked in the mobile view of the dashboard banner.
Name | Type | Access | Description |
---|---|---|---|
menuItems | get | Will holds the array of menu list |
Example
var dashboard = BoldBI.create({
beforeDashboardMobileMenuOpen: function (args) {
// Write a code block to operate after more option from the dashboard banner is clicked in the mobile view.
}
});
dashboard.loadDashboard();
This event will be triggered before the URL linking navigations are called.
Name | Type | Access | Description |
---|---|---|---|
type | get | Will holds the current event type that triggered the event | linkInfo | set | Will holds the linking information |
model | get | Holds the dashboard viewer's object. | |
widgetId | string | get | Holds the current widget id information |
widgetName | string | get | Holds the current widget name information |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
beforeNavigateUrlLinking: function (args) {
// Write a code block to perform an operation before the url linking navigation called.
}
});
dashboard.loadDashboard();
This event is used to catch any errors that may occur during the embedding process.
Name | Type | Access | Description |
---|---|---|---|
args | get | Holds the args Object like below. 1. args.errorStatus - Its boolean value if there is an error value is true. 2. args.StatusMessage - Holds the error details 3. args.StatusCode - Holds the status Code of the error. |
Example: Try to embed the designer in view mode.
var dashboard = BoldBI.create({
dashboardId: "5cb065f7-dabb-4b0c-9b45-c60a5730e963",
mode: BoldBI.Mode.view,
onError: function (args) {
// Expected Error details.
//args.errorStatus will contains true value.
//args.StatusMessage will contains "Error : Inavlid Embed Mode".
//args.StatusCode will contains 500 as statusCode
}
});
dashboard.loadDashboard();
This event will be triggered when you change the layout of the pinboard.
Name | Type | Access | Description |
---|---|---|---|
args | get | Holds the Dashboard Viewers Object like below. 1. ServerUrl - BoldBI server URL passed to render the dashboard. 2. itemId - Unique id of the BoldBI Dashboard. 3. dashboardName - Unique name of the BoldBI Dashboard. |
Example
var dashboard = BoldBI.create({
onLayoutChange: function (args) {
// Write a code block to operate when you change the layout of the pinboard.
}
});
dashboard.loadPinboard();
This event will be triggered before the datasource toolbar buttons are rendered. You can add or remove buttons in the toolbar with this event.
Name | Type | Description | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
args.toolbarButtons | array[] | Holds the details of datasource toolbar Buttons.
|
Example for adding new button in datasource toolbar
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Datasource,
dashboardSettings: {
beforeDatasourceToolbarButtonsRendered: function (args) {
// Write a code block to add a new button before the datasource toolbar buttons were rendered.
// args.toolbarButtons.push({
// class:'new-button-class',
// elementId:'new-button-id',
// isActionBtn:true,
// label:'External button'
// });
}
}
});
dashboard.loadDatasource();
Example for removing a button from the datasource page
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Connection,
dashboardSettings: {
beforeDatasourceToolbarButtonsRendered: function (args) {
// Write a code block to remove an existing button before the datasource tool toolbar buttons were rendered.
// args.toolbarButtons.forEach(function (button, index, object) {
// if (button.label == "Cancel") {
// object.splice(index, 1);
// }
// });
}
}
});
dashboard.loadDatasource();
This event will be triggered before the datasource toolbar icons are rendered. You can add or remove icons in the toolbar using this event.
Name | Type | Description | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
args.toolbarIcons | array[] | Holds the details of the datasource toolbar Icons.
|
Example for adding new icon in datasource toolbar
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Datasource,
dashboardSettings: {
beforeDatasourceToolbarIconsRendered: function (args) {
// Write a code block to add an external icon other than Bold BI before the data source toolbar icons are rendered.
// args.toolbarIcons.push({
// class:'fa fa-comments',
// iconType:'custom',
// iconTooltip:'Comment',
// label:'Comment'
// });
}
}
});
dashboard.loadDatasource();
Example for removing a icon from the datasource toolbar
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Datasource,
dashboardSettings: {
beforeDatasourceToolbarIconsRendered: function (args) {
// Write a code block to remove an existing button before the datasource toolbar icons were rendered.
// args.toolbarIcons.forEach(function (icon, index, object) {
// if (icon.label == "Run") {
// object.splice(index, 1);
// }
// });
}
}
});
dashboard.loadDatasource();
This event will be triggered before the toolbar buttons are rendered.
Name | Type | Description | ||||||
---|---|---|---|---|---|---|---|---|
args.toolbarButtons | array[] | Holds the details all the tool bar Buttons.
|
Example For adding new button
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Design,
dashboardSettings: {
beforeDesignerToolbarButtons: function (args) {
// Write a code block to add an external button before the dashboard banner buttons are rendered.
// args.toolbarButtons.push({
// class:'new-btn-class',
// elementId:'new-button-id',
// label:'External Button',
// });
}
}
});
dashboard.loadDesigner();
Example For removing a button
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Design,
dashboardSettings: {
beforeDesignerToolbarButtons: function (args) {
// Write a code block to remove an existing button before the dashboard banner buttons are rendered.
// args.toolbarButtons.forEach(function (button, index, object) {
// if (button.label == "Preview") {
// object.splice(index, 1);
// }
// });
}
}
});
dashboard.loadDesigner();
This event will be triggered before the designer toolbar icons are rendered. You can add or remove icons in the toolbar using this event.
Name | Type | Description | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
args.toolbarIcons | array[] | Holds the details of the designer toolbar Icons.
|
Example for adding new icon in designer toolbar
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Design,
dashboardSettings: {
beforeDesignerToolbarIconsRendered: function (args) {
// Write a code block to add an external icon other than boldbi before the designer toolbar icons were rendered.
// args.toolbarIcons.push({
// class:'fa fa-comments',
// iconType:'custom',
// iconTooltip:'Comment',
// label:'Comment'
// });
}
}
});
dashboard.loadDesigner();
Example for removing a icon from designer toolbar
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Design,
dashboardSettings: {
beforeDesignerToolbarIconsRendered: function (args) {
// Write a code block to remove an existing icon before the designer toolbar icons are rendered.
// args.toolbarIcons.forEach(function (icon, index, object) {
// if (icon.label == "Undo") {
// object.splice(index, 1);
// }
// });
}
}
});
dashboard.loadDesigner();
dashboardSettings.beforeIconRender
This event will be triggered before the dashboard banner icons are rendered.
Name | Type | Access | Description |
---|---|---|---|
type | get | Will holds the current event type that triggered the event | |
model | get | Holds the dashboard viewer's object. | |
iconsinformation | array | set | Holds the information about the list of icons to be rendered in the Dashboard. |
enableComment | boolean | get | Holds the enableComment value. |
dashboardPath | string | get | Holds the current dashboard path value. |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
dashboardSettings: {
beforeIconRender: function (args) {
// Write a code block to perform an operation before the dashboard banner icons were rendered
}
}
});
dashboard.loadDashboard();
This event will be triggered by the following actions.
Publish
or Save
the new dashboard.PublishAs
or SaveAs
the existing dashboards.Name | Type | Description |
---|---|---|
args.source.data.dashboardId | string | Holds the unique GUID for the dashboard. |
args.source.data.dashboardName | string | Holds the name of the dashboard. |
args.source.data.dashboardDescription | string | Holds the description of the dashboard. |
args.source.data.isPublicDashboard | string | Holds the dashboard is public or not. |
Example
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Design,
dashboardSettings:
{
beforePublishAs: function (args) {
//Write a code block to perform an operation before publish the dashboard.
//Write a code block to perform an operation before publish the dashboard.
}
}
});
dashboard.loadDesigner();
dashboardSettings.beforeSaveAsViewDialogOpen
This event will be triggered when the save as icon in the filter overview panel is clicked.
Name | Type | Description | |
---|---|---|---|
type | enum | get | Will holds the current event type that triggered the event |
model | get | Holds the dashboard viewer's object. | |
data | object | get | Holds the current event data. |
viewId | string | get | Holds the Id of the view. |
viewName | string | get | Holds the name of the view. |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
dashboardSettings: {
beforeSaveAsViewDialogOpen: function(args) {
// embedContainerID -> 'dashboard'
var instance = BoldBI.getInstance('dashboard');
// Get the dashboard ID from the embedOptions
var itemId = instance.embedOptions.dashboardId;
// Get the encrypted filter querystring from the event arguments
var queryString = args.data.encryptedData;
// Determine the active-tabbed child dashboard ID if it's a multi-tab dashboard
var childItemId = instance.isMultiTab ? instance._getActiveChildDashboardId() : '';
// You can set your view as DefaultView after the default view option is enabled in dashboard settings in the Bold BI server. Otherwise, it will be false as the default value.
var isDefaultView = true;
/* Add custom functionality for cloning the view into the dashboard */
// Call the API method ('saveFilterView') to save as the view and specify a callback function ('callBackFunction') to handle the response and perform further actions.
instance.saveAsFilterView({
'ViewName': 'Filter View name',
'ItemId': itemId,
'QueryString': queryString,
'ChildItemId': childItemId,
'IsDefault': isDefaultView
}, 'callBackFunction');
}
}
});
dashboard.loadDashboard();
dashboardSettings.beforeSaveViewDialogOpen
This event will be triggered when the save icon in the filter overview panel is clicked.
Name | Type | Description | |
---|---|---|---|
type | enum | get | Will hold the current event type that triggered the event |
model | get | Holds the dashboard viewer's object. | |
data | object | get | Holds the current event data. |
viewId | string | get | Holds the Id of the view if the view has already been saved. |
viewName | string | get | Holds the name of the view if the view has already been saved. |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example for saving a new view
var dashboard = BoldBI.create({
dashboardSettings: {
beforeSaveViewDialogOpen: function(args) {
// embedContainerID -> 'dashboard'
var instance = BoldBI.getInstance('dashboard');
// Get the dashboard ID from the embedOptions.
var itemId = instance.embedOptions.dashboardId;
// Get the encrypted filter querystring from the event arguments.
var queryString = args.data.encryptedData;
// Determine the active-tabbed child dashboard ID if it is a multi-tab dashboard.
var childItemId = instance.isMultiTab ? instance._getActiveChildDashboardId() : '';
// You can set your view as DefaultView after the default view option is enabled in dashboard settings in the Bold BI server. Otherwise, it will be false as the default value.
var isDefaultView = true;
/* Add custom functionality for saving the view into the dashboard */
// Call the API method ('saveFilterView') to save the view and specify a callback function ('callBackFunction') to handle the response and perform further actions.
instance.saveFilterView({
'ViewName': 'Filter View name',
'ItemId': itemId,
'QueryString': queryString,
'ChildItemId': childItemId,
'IsDefault': isDefaultView
}, 'callBackFunction');
}
}
});
dashboard.loadDashboard();
Example for updating the existing view
var dashboard = BoldBI.create({
dashboardSettings: {
beforeSaveViewDialogOpen: function(args) {
// embedContainerID -> 'dashboard'
var instance = BoldBI.getInstance('dashboard');
// Get the view ID from the event arguments.
var viewId = args.viewId;
// Determine the active-tabbed child dashboard ID if it is a multi-tab dashboard.
var dashboardId = instance.isMultiTab ? instance._getActiveChildDashboardId() : instance.embedOptions.dashboardId;
// Get the encrypted filter querystring from the event arguments
var queryString = args.data.encryptedData;
// You can set your view as DefaultView after the default view option is enabled in dashboard settings in the Bold BI server. Otherwise, it will be false as the default value.
var isDefaultView = true;
/* Add custom functionality for updating the view in the dashboard */
// Call the API method ('updateFilterView') to update the view and specify a callback function ('callBackFunction') to handle the response and perform further actions.
instance.updateFilterView({
'ViewId': viewId,
'DashboardId': dashboardId,
'QueryString': queryString,
'IsDefault': isDefaultView
}, 'callBackFunction');
}
}
});
dashboard.loadDashboard();
dashboardSettings.onIconClick
This event will be triggered when an icon from the dashboard banner is clicked.
Name | Type | Access | Description |
---|---|---|---|
type | get | Will holds the current event type that triggered the event | |
model | get | Holds the dashboard viewer's object. | |
target | array | get | Contains the parent element of the selected icon.. |
name | string | get | Contains the name of the icon clicked. |
dashboardPath | string | get | Holds the current dashboard path value. |
headertext | string | get | Contains the title of the dashboard. |
event | object | get | Returns the current click event information like below.
1. currentTarget - It indicates the current DOM element 2. type - It indicates the click event. |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
dashboardSettings: {
onIconClick: function (args) {
// Write a code block to perform an operation after an icon from dashboard banner is clicked
}
}
});
dashboard.loadDashboard();
dashboardSettings.onInteraction
This event will be triggered once the master widget applying and clearing filters are completed.
Name | Type | Access | Description |
---|---|---|---|
eventType | string | get | Will holds the current event type that triggered the event. |
model | get | Holds the dashboard viewer's object. | |
source.data | object | get | Holds the master widget and its filter values details. |
type | string | get | Holds the parent event type of the current event. |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
dashboardSettings: {
onInteraction: function (args) {
// Write a code block to operate after a master widget interaction is completed.
}
}
});
dashboard.loadDashboard();
dashboardSettings.onViewSavedFiltersClick
This event will be triggered when the “view saved filters” icon in the filter overview panel is clicked.
Name | Type | Description | |
---|---|---|---|
type | enum | get | Will holds the current event type that triggered the event |
model | get | Holds the dashboard viewer's object. | |
data | object | get | Holds the current event data. |
target | array | get | Holds the target of the current element in html. |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
dashboardSettings: {
onViewSavedFiltersClick: function(args) {
// embedContainerID -> 'dashboard'
var instance = BoldBI.getInstance('dashboard');
// Determine the active-tabbed child dashboard ID if it's a multi-tab dashboard
// Get the dashboard id from the embed options
var dashboardId = instance.isMultiTab ? instance._getActiveChildDashboardId() : instance.embedOptions.dashboardId;
/* Add custom functionality for getting views from the dashboard */
// Call the API method ('getViewsByDashboardId') for getting the views and specify a callback function ('callBackFunction') to handle the response and perform further actions.
instance.getViewsByDashboardId(dashboardId, 'callBackFunction');
}
}
});
dashboard.loadDashboard();
This event will be triggered when the designer toolbar icon/button is clicked.
Name | Type | Access | Description |
---|---|---|---|
click | string | get | Holds the name of the icon/button clicked. |
model | get | Holds the dashboard designer's object. | |
target | array | get | Contains the parent element of the selected icon/button. |
type | get | Holds the current event type. | |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Design,
dashboardSettings: {
toolbarClick: function (args) {
// if (args.click == "Copy")
// Write a code block to perform an operation when the Copy icon from designer toolbar is clicked.
// if (args.click == "Preview")
// Write a code block to perform an operation when the Preview button from designer toolbar is clicked.
}
}
});
dashboard.loadDesigner();
This event will be triggered after the save action of the data source is called.
Name | Type | Access | Description |
---|---|---|---|
eventType | get | Will holds the current event type that triggered the event | |
model | get | Holds the Data source Viewer's Object. | |
designer | object | get | Holds the information about the dashboard designer . |
dataSourceId | string | get | Holds the current data source id. |
schema | object | get | Holds the current data source schema information such as data base table name, table Id, and so on. | status | boolean | get | Holds the status of the data source save action |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Datasource,
afterDatasourceSave: function (args) {
// Write a code block to perform an operation after the data source save action is called
}
});
dashboard.loadDatasource();
This event will be triggered before the save action of the data source is called.
Name | Type | Access | Description |
---|---|---|---|
eventType | get | Will holds the current event type that triggered the event | |
model | get | Holds the Data source Viewer's Object. | |
designer | object | get | Holds the information about the dashboard designer. |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Datasource,
beforeDatasourceSave: function (args) {
// Write a code block to perform an operation before the data source save action is called
}
});
dashboard.loadDatasource();
This event will be triggered after the filter has been applied.
Name | Type | Access | Description |
---|---|---|---|
eventType | get | Will holds the current event type that triggered the event | |
model | get | Holds the dashboard viewer's object. | |
source | get | This will contain the data related to the current event 1. element - Which holds the DOM element. 2. data |
|
source.data | get | Holds the current event data. | |
source.data.widgetName | string | get | Holds the interacted widget name information |
source.data.widgetProperties | get | Holds the Widget properties of interacted widget as like,UniqueId which represent Widget Id of the interacted widget. | |
source.data.selectedFilterValues | array | set | Holds the filter values of interacted widget and able to modify the filter values here. |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
afterFilterApply: function (args) {
// Write a code block to operate after the filter is applied.
}
});
dashboard.loadDashboard();
This event will be triggered before the filter is applied.
Name | Type | Access | Description |
---|---|---|---|
eventType | get | Holds the current event type that triggered the event | |
model | get | Holds the dashboard viewer's object. | |
source | get | This will contain the data related to the current event as like below. 1. element - Which holds the DOM elements. 2. data |
|
source.data | get | Holds the current event data. | |
source.data.widgetName | string | get | Holds the interacted widget name information |
source.data.widgetProperties | get | Holds the Widget properties of interacted widget as like below. 1. UniqueId - It denotes the interacted widget Id |
|
source.data.selectedFilterValues | array | get | Holds the Filter Values of interacted widget. | cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
beforeFilterApply: function (args) {
// Write a code block to operate before the filter is applied.
}
});
dashboard.loadDashboard();
This event will be triggered when you perform the drag widget on the pinboard.
Name | Type | Access | Description |
---|---|---|---|
args | get | Holds the Dashboard Viewers Object as follows. 1. ServerUrl - Bold BI server URL is passed to render the dashboard. 2. itemId - Unique id of the BoldBI Dashboard. 3. dashboardName - Unique name of the BoldBI Dashboard. |
Example
var dashboard = BoldBI.create({
onDrag: function (args) {
// Write a code block to operate when you drag the widget from the pinboard.
}
});
dashboard.loadPinboard();
This event will be triggered when you drop the widget.
Name | Type | Access | Description |
---|---|---|---|
args | get | Holds the Dashboard Viewers Object as follows. 1. ServerUrl - Bold BI server URL is passed to render the dashboard. 2. itemId - Unique id of the BoldBI Dashboard. 3. dashboardName - Unique name of the BoldBI Dashboard. |
Example
var dashboard = BoldBI.create({
onDrop: function (args) {
// Write a code block to operate when you drop the widget in the pinboard.
}
});
dashboard.loadPinboard();
This event will be triggered when you resize the pinboard.
Name | Type | Access | Description |
---|---|---|---|
args | get | Holds the Dashboard Viewers Object like below. 1. ServerUrl - BoldBI server URL passed to render the dashboard. 2. itemId - Unique id of the BoldBI Dashboard. 3. dashboardName - Unique name of the BoldBI Dashboard. |
Example
var dashboard = BoldBI.create({
onResize: function (args) {
// Write a code block to operate when you resize the pinboard.
}
});
dashboard.loadPinboard();
This event will be triggered when you remove the widget from the pinboard.
Name | Type | Access | Description |
---|---|---|---|
args | get | Holds the Dashboard Viewers Object as follows. 1. ServerUrl - Bold BI server URL is passed to render the dashboard. 2. itemId - Unique id of the Bold BI Dashboard. 3. dashboardName - Unique name of the Bold BI Dashboard. |
Example
var dashboard = BoldBI.create({
onUnpin: function (args) {
// Write a code block to perform an operation click the unpin widget.
}
});
dashboard.loadPinboard();
This event will be triggered before the widget item panel is rendered. You will be able to remove a specific group or specific widget item in the item panel using the event.
Note: This event will be triggered again if the preConfiguredWidgets API is enabled.
Name | Type | Description |
---|---|---|
args.widgetInfo | array[] | Holds the details of the widget groups like GroupName and GroupId. |
args.widgetInfo.Items | array[] | Holds the details of the widget items like id, tooltip, widgetDisplayName and so on. |
Example for removing a existing group
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Design,
widgetSettings: {
beforeWidgetItemsListed: function (args) {
// Write a code block to remove an 'Comparison' group before the widget panel is rendered.
// args.widgetInfo.forEach(function (group, index, object) {
// if (group.GroupName == "Comparison") {
// object.splice(index, 1);
// }
// });
}
}
});
dashboard.loadDesigner();
Example for removing a existing widget from specific group
var dashboard = BoldBI.create({
mode: BoldBI.Mode.Design,
widgetSettings: {
beforeWidgetItemsListed: function (args) {
// Write a code block to remove an 'Bar' widget before the widget panel is rendered.
// args.widgetInfo.forEach(function (group, gIndex, gObject) {
// if (group.GroupName == "Comparison") {
// group.Items.forEach(function (item, iIndex, iObject) {
// if (item.widgetDisplayName == "Bar") {
// iObject.splice(iIndex, 1);
// }
// });
// }
// });
}
});
dashboard.loadDesigner();
This event will be triggered before the widget banner icons are rendered.
Name | Type | Access | Description |
---|---|---|---|
type | get | Will holds the current event type that triggered the event | |
model | get | Holds the dashboard viewer's object. | |
widgetInformation | object | get | Holds the current triggered widget information as like below. 1. fontColor - Color of font in widget. 2. fontFamily - fontFamily of the text in the widget 3. type - Indicates the type of the widget like, grid, chart and so on,.. |
uniqueId | string | get | Holds the current widget id. |
iconsinformation | array | set | Holds the information about the list of icons to be rendered in the dashboard. |
isFilterWidget | boolean | get | Holds the true, if the current widget is filter. |
dashboardComment | boolean | get | Holds the dashboardComment value. |
enableComment | boolean | get | Holds the enableComment value. |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
widgetSettings: {
beforeIconRender: function (args) {
// Write a code block to perform an operation before the widget banner icons were rendered
}
}
});
dashboard.loadDashboard();
This event will be triggered after clicking on any option from the control menu icon.
Name | Type | Description |
---|---|---|
type | Will holds the current event type that triggered the event | |
model | Holds the Dashboard Viewer's Object. | |
header | string | Contains the title of the widget. |
menuItem | array | Contains array value present in the widget control menu. |
widgetId | string | Holds the id of the widget where the menu icon is clicked. |
cancel | boolean | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
widgetSettings: {
beforeWidgetControlMenuOpen: function (args) {
// Write a code block to perform an operation after control menu icon from the widget banner is clicked.
}
}
});
dashboard.loadDashboard();
This event will be triggered when an icon from the widget banner is clicked.
Name | Type | Access | Description |
---|---|---|---|
type | get | Will holds the current event type that triggered the event | |
model | get | Holds the dashboard viewer's object. | |
target | array | get | Contains the parent element of the selected icon. |
name | string | get | Contains the name of the icon clicked. |
dashboardPath | string | get | Holds the current dashboard path value. |
headertext | string | get | Contains the title of the widget. |
event | object | get | Returns the current click event information as like below. 1. type - It indicates the type of event, here it is click. 2. currentTarget - It indicates the current DOM element |
widgetId | string | get | Holds the id of the widget where the menu icon is clicked. |
dataWidgetId | string | get | Holds the id of the widget where the menu icon is clicked. |
cancel | boolean | set | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
widgetSettings: {
onIconClick: function (args) {
// Write a code block to perform an operation after an icon from widget banner is clicked
}
}
});
dashboard.loadDashboard();
This event will be triggered after clicking any option from the control menu icon.
Name | Type | Description |
---|---|---|
type | Will holds the current event type that triggered the event | |
model | Holds the Dashboard Viewer's Object. | |
header | string | Contains the title of the widget. |
menu | array | Contains details of newly added button in widget control menu. |
widgetId | string | Holds the id of the widget where the menu icon is clicked. |
cancel | boolean | Holds the cancel value of the current operation. |
Example
var dashboard = BoldBI.create({
widgetSettings: {
onWidgetControlMenuClick: function (args) {
// Write a code block to perform an operation after any option from control menu icon from widget banner is clicked.
}
dashboard.loadDashboard();
}
});
This section describes the dashboard properties of the viewer object correctly.
Name | Type | Access | Description |
---|---|---|---|
serverUrl | string | get | Hold the Bold BI server URL. |
itemId | string | get | Hold the unique id of the dashboard. |
dashboardDescription | string | get | Hold the description of dashboard. |
dashboardName | string | get | Hold the name of the dashboard is rendered. |
environment | string | get | Hold the embedding environment type. |
mode | string | get | Hold the mode of the dashboard. |
This section describes the data source properties of the viewer object.
Name | Type | Access | Description |
---|---|---|---|
serverUrl | string | get | Hold the Bold BI server URL. |
datasource | string | get | Hold the unique id of the data source. |
datasourceName | string | get | Hold the data source name. |
environment | string | get | Hold the embedding environment type. |
mode | string | get | Hold the mode of the data source. |