/api/reports/views/:id/table/jsonindicators/:iid/conditions/createこのメソッドは、選択した表インジケーターの条件付き書式を作成します。この方法は、JSONフォーマットでテーブルを返却します。 リソース情報リクエストパラメータリクエストパラメーターパラメーター | 詳細 | 例 |
---|
id
| テーブルのID。このIDはID of the table. This ID is part of the /api/reports/:id | responseの一部です。 response. | 123 | filter
| (任意)次の構造でテーブルに適用されたフィルタ: | |
---|
drilldown | ドリルダウンが属性コードと次のような構造で定義されました | |
---|
op | フィルタ操作タイプ - サポートされている値のリストをご参照してください。 | value/values | (任意)選択した「op」に依存します。フィルタの値または値を格納します。 |
|
Code Block |
---|
{
"drilldown": {
"L_COUNTRY_OR_AREA": { "op": "EQ", "value": "Slovakia"},
"L_TYPE": { "op": "IN", "values": [ "Type 1", "Type 2", "Type 3" ]},
"L_DATE":{"op":"NOT_NULL"}
}
} |
|
レスポンスの構造 Code Block |
---|
{
"rowsCount" : ...,
"name" : ...,
"header" : [ ],
"body" : [ ]
} |
JSONレスポンスは、次の定義を持つ要素が含まれます。 名 | 説明 |
---|
rowsCount | ヘッダーとデータを含む総数行 | name | テーブルビュー名 | header | ヘッダ要素を含む配列 | body | データ要素を含む配列 |
サンプルリクエスト/レスポンスiid
| ID of the indicator. This ID is part of the /api/views/:id/table/indicators response. | AVn6TNRofe | data | Form contents to submit in following JSON format: evaluationType | Type of conditional formatting (INDICATOR or FORMULA) | symbol | Symbol of the conditional formatting (ARROW_UP, ARROW_DOWN, WARNING, etc. - see Types and enumerations) | compareValue | Compare value | compareFormula | Compare formula (used when compareType=FORMULA_INDICATOR or evaluationType=FORMULA) | condition | Use conditions (EQ, BW, GTW, etc. - see Types and enumerations) | value | Secondary value, used for conditions BW, NOT_BW, GBY, LBY | compareType | Type of compare value (CONSTANT, PREV_VALUE, FORMULA_INDICATOR, INDICATOR) | color | Color of text | background | Background color | description | Description | cssClass | (optional) custom css style |
|
Code Block |
---|
{
"evaluationType": "INDICATOR",
"value":5,
"compareValue": 15,
"symbol": "WARNING",
"condition": "BW",
"compareType": "CONSTANT",
"color": "#15d000",
"background": "#8bffc5"
} |
|
レスポンス構造JSON response contains one JSON object with the following element: index | Order of the condition |
サンプルリクエスト/レスポンスcurl使用 Curl使用:
Code Block |
---|
curl -H "Authorization: OAuth realm=\"https://service.belladati.com/\", oauth_consumer_key=\"myConsumer\", oauth_token=\"mh7an9dkrg59\", oauth_timestamp=\"135131231\", oauth_nonce=\"randomString\"" https://service.belladati.com/api/reports/views/1234/table/json
|
JSONフォーマットの応答: Code Block |
---|
{
"rowsCount" : 5,
"name" : "My Table Name",
"header" : [
[
{
"value" : "",
"type" : "header"
}
],
[
{
"value" : "",
"type" : "header"
}
]
],
"body" : [
[
{
"value" : "Value",
"type" : "header"
},
{
"style" : " color:rgb(77, 77, 77) !important ; background-color:rgb(237, 237, 237); ",
"value" : "1,033,054,533,155"
}
],
[
{
"value" : "Value Footnotes",
"type" : "header"
},
{
"style" : " color:rgb(77, 77, 77) !important ; background-color:rgb(237, 237, 237); ",
"value" : "1"
}
],
[
{
"value" : "B",
"type" : "header"
},
{
"style" : " color:rgb(77, 77, 77) !important ; background-color:rgb(237, 237, 237); ",
"value" : "5"
}
]
]
} | Next steps-d "data={\"evaluationType\": \"INDICATOR\",\"value\":5,\"compareValue\": 15,\"symbol\": \"WARNING\",\"condition\": \"BW\",\"compareType\": \"CONSTANT\",\"color\": \"#15d000\",\"background\": \"#8bffc5\"}" https://service.belladati.com/api/reports/views/5672-UXF46PMUR7/table/indicators/AVn6TNRofe/conditions/create
|
JSON形式のレスポンス: |