Skip to main content

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent”></a> Interface IDashboardAgent

Namespace: SuperOffice.WebApi.Agents
Assembly: SuperOffice.WebApi.dll
Agent lets you configure dashboard tiles and retrieve dashboard data

Implements

IDisposable

Methods

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_CreateDefaultDashboardAsync_SuperOffice_WebApi_RequestOptions_”></a> CreateDefaultDashboardAsync(RequestOptions)

Set default values into a new Dashboard. NetServer calculates default values on the entity, which is required when creating/storing a new instance

Parameters

requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<Dashboard&gt; A blank Dashboard

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_CreateDefaultDashboardTileAsync_SuperOffice_WebApi_RequestOptions_”></a> CreateDefaultDashboardTileAsync(RequestOptions)

Set default values into a new DashboardTile. NetServer calculates default values on the entity, which is required when creating/storing a new instance

Parameters

requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<DashboardTile&gt; A blank DashboardTile

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_CreateNewFromTemplateAsync_System_Int32_System_String_System_String_System_Int32_SuperOffice_WebApi_Data_VisibleFor___SuperOffice_WebApi_RequestOptions_”></a> CreateNewFromTemplateAsync(int, string, string, int, VisibleFor[], RequestOptions)

Create new tile from another tile used as template

Parameters

dashboardTileId int Tile template Id caption string Caption of new tile description string Description of new tile selectionId int Selection id of new tile visibleFor VisibleFor[] Who the tile should be visible for requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<DashboardTile&gt; The new tile

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_DeleteDashboardAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> DeleteDashboardAsync(int, RequestOptions)

Deletes the Dashboard

Parameters

dashboardId int The identity of the Dashboard requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_DeleteDashboardTileAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> DeleteDashboardTileAsync(int, RequestOptions)

Deletes the DashboardTile

Parameters

dashboardTileId int The identity of the DashboardTile requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_GetDashboardAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetDashboardAsync(int, RequestOptions)

Gets a specific Dashboard object.

Parameters

dashboardId int The identifier of the Dashboard object requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<Dashboard&gt; Dashboard

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_GetDashboardTileAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetDashboardTileAsync(int, RequestOptions)

Gets a specific DashboardTile object.

Parameters

dashboardTileId int The identifier of the DashboardTile object requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<DashboardTile&gt; DashboardTile

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_GetDashboardTilesAsync_System_Int32___SuperOffice_WebApi_RequestOptions_”></a> GetDashboardTilesAsync(int[], RequestOptions)

Gets an array of dashboard tiles for the provided ids

Parameters

dashboardTileIds int[] The ids of the tiles to get requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<DashboardTile[]&gt; Dashboard tiles

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_GetDashboardsAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetDashboardsAsync(int, RequestOptions)

Gets all dashboards for an associate

Parameters

associateId int Associate Id requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<Dashboard[]&gt; All the users dashboards

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_GetDataAsync_System_Int32_System_String_SuperOffice_WebApi_RequestOptions_”></a> GetDataAsync(int, string, RequestOptions)

Get data for this tile

Parameters

dashboardTileId int Tile Id restrictions string Replacement restrictions requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<TileData[]&gt; The data

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_GetDataWithSelectionAsync_System_Int32_System_Int32_System_String_SuperOffice_WebApi_RequestOptions_”></a> GetDataWithSelectionAsync(int, int, string, RequestOptions)

Get data for this tile

Parameters

dashboardTileId int Tile Id selectionId int Selection Id restrictions string Replacement restrictions requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<TileData[]&gt; The data

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_GetStandardDashboardTileFromChartIdAsync_System_String_SuperOffice_WebApi_RequestOptions_”></a> GetStandardDashboardTileFromChartIdAsync(string, RequestOptions)

Gets the standard tile (not personal tile) corresponding to the given chart id

Parameters

chartId string The ChartId of the wanted chart/tile requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<DashboardTile&gt; Standard tile

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_SaveDashboardAsync_SuperOffice_WebApi_Data_Dashboard_SuperOffice_WebApi_RequestOptions_”></a> SaveDashboardAsync(Dashboard, RequestOptions)

Updates the existing Dashboard or creates a new Dashboard if the id parameter is 0.

Parameters

dashboard Dashboard The Dashboard that is saved. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<Dashboard&gt; New or updated Dashboard

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_SaveDashboardTileAsync_SuperOffice_WebApi_Data_DashboardTile_SuperOffice_WebApi_RequestOptions_”></a> SaveDashboardTileAsync(DashboardTile, RequestOptions)

Updates the existing DashboardTile or creates a new DashboardTile if the id parameter is 0.

Parameters

dashboardTile DashboardTile The DashboardTile that is saved. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<DashboardTile&gt; New or updated DashboardTile

<a id=“SuperOffice_WebApi_Agents_IDashboardAgent_SetTileAsync_System_Int32_System_Int32_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> SetTileAsync(int, int, int, RequestOptions)

Sets tile in the given dashboard position

Parameters

dashboardId int Dashboard Id tileId int Tile Id position int Tile position in the dashboard requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<Dashboard&gt; The new dashboard is returned after the tile change