This is a translation of the original English documentation page. Help us make it better.

24 SLA report

説明

これらのパラメーターと、各ダッシュボードウィジェットフィールドオブジェクトの有効なプロパティ値を使用することで、dashboard.createメソッドおよびdashboard.updateメソッドでSLAレポートウィジェットを設定できます。

ウィジェットのfieldsプロパティは、ダッシュボードの作成または更新時に検証されません。 これにより、ユーザーは組み込みウィジェットを変更したり、カスタムウィジェットを作成したりできますが、ウィジェットを誤って作成または更新してしまうリスクも生じます。 SLAレポートウィジェットを正常に作成または更新するには、以下の表に記載されているパラメーターの動作を参照してください。

Parameters

The following parameters are supported for the SLA report widget.

Parameter type name value
Refresh interval 0 rf_rate 0 - (default) No refresh;
10 - 10 seconds;
30 - 30 seconds;
60 - 1 minute;
120 - 2 minutes;
600 - 10 minutes;
900 - 15 minutes.
SLA
(required)
10 slaid SLA ID.
Service 9 serviceid Service ID.
Show periods 0 show_periods Valid values range from 1-100.

Default: 20.
From 1 date_from Valid date string in format YYYY-MM-DD.
Relative dates with modifiers d, w, M, y (e.g. now, now/d, now/w-1w, etc.) are supported.
To 1 date_to Valid date string in format YYYY-MM-DD.
Relative dates with modifiers d, w, M, y (e.g. now, now/d, now/w-1w, etc.) are supported.

次の例は、SLA reportウィジェットのダッシュボードウィジェットフィールドオブジェクトの設定を説明することだけを目的としています。 ダッシュボードの設定の詳細については、dashboard.createを参照してください。

Configuring an SLA report widget

Configure an SLA report widget that displays the SLA report for SLA "4" service "2" for the period of last 30 days.

Request:

{
           "jsonrpc": "2.0",
           "method": "dashboard.create",
           "params": {
               "name": "My dashboard",
               "display_period": 30,
               "auto_start": 1,
               "pages": [
                   {
                       "widgets": [
                           {
                               "type": "slareport",
                               "name": "SLA report",
                               "x": 0,
                               "y": 0,
                               "width": 12,
                               "height": 5,
                               "view_mode": 0,
                               "fields": [
                                   {
                                       "type": 10,
                                       "name": "slaid",
                                       "value": 4
                                   },
                                   {
                                       "type": 9,
                                       "name": "serviceid",
                                       "value": 2
                                   },
                                   {
                                       "type": 1,
                                       "name": "date_from",
                                       "value": "now-30d"
                                   },
                                   {
                                       "type": 1,
                                       "name": "date_to",
                                       "value": "now"
                                   }
                               ]
                           }
                       ]
                   }
               ],
               "userGroups": [
                   {
                       "usrgrpid": 7,
                       "permission": 2
                   }
               ],
               "users": [
                   {
                       "userid": 1,
                       "permission": 3
                   }
               ]
           },
           "id": 1
       }

Response:

{
           "jsonrpc": "2.0",
           "result": {
               "dashboardids": [
                   "3"
               ]
           },
           "id": 1
       }

参照