Hello:
Voilà:
[
{
"id": "1066",
"name": null,
"type": "if",
"options": [],
"order": "0",
"subElements": [
{
"id": "2779",
"name": null,
"scenarioElement_id": "1066",
"type": "if",
"subtype": "condition",
"options": {
"collapse": "0",
"enable": "1",
"allowRepeatCondition": "0"
},
"order": "0",
"expressions": [
{
"id": "3279",
"scenarioSubElement_id": "2779",
"type": "condition",
"subtype": null,
"expression": "#[Maison][R\u00e9sum\u00e9][Pluie 24h]# == 0 ",
"options": [],
"order": "0"
}
]
},
{
"id": "2780",
"name": null,
"scenarioElement_id": "1066",
"type": "then",
"subtype": "action",
"options": [],
"order": "1",
"expressions": [
{
"id": "3281",
"scenarioSubElement_id": "2780",
"type": "action",
"subtype": null,
"expression": "delete_variable",
"options": {
"enable": "1",
"background": "0",
"name": "Pluies_24h"
},
"order": "0"
},
{
"id": "3322",
"scenarioSubElement_id": "2780",
"type": "action",
"subtype": null,
"expression": "event",
"options": {
"enable": "1",
"background": "0",
"cmd": "#[Maison][R\u00e9sum\u00e9][Pluie J+1]#",
"value": "max(#[Maison][R\u00e9sum\u00e9][Pluie 24h]#,yesterday)"
},
"order": "1"
},
{
"id": "3339",
"scenarioSubElement_id": "2780",
"type": "element",
"subtype": null,
"expression": "1080",
"options": [],
"order": "2",
"element": {
"id": "1080",
"name": null,
"type": "in",
"options": [],
"order": "0",
"subElements": [
{
"id": "2810",
"name": null,
"scenarioElement_id": "1080",
"type": "in",
"subtype": "condition",
"options": {
"collapse": "0",
"enable": "1"
},
"order": "0",
"expressions": [
{
"id": "3337",
"scenarioSubElement_id": "2810",
"type": "condition",
"subtype": null,
"expression": "1440",
"options": [],
"order": "0"
}
]
},
{
"id": "2811",
"name": null,
"scenarioElement_id": "1080",
"type": "do",
"subtype": "action",
"options": [],
"order": "1",
"expressions": [
{
"id": "3338",
"scenarioSubElement_id": "2811",
"type": "action",
"subtype": null,
"expression": "scenario",
"options": {
"enable": "1",
"background": "0",
"scenario_id": "106",
"action": "start",
"tags": ""
},
"order": "0"
}
]
}
]
}
}
]
},
{
"id": "2781",
"name": null,
"scenarioElement_id": "1066",
"type": "else",
"subtype": "action",
"options": [],
"order": "2",
"expressions": [
{
"id": "3307",
"scenarioSubElement_id": "2781",
"type": "action",
"subtype": null,
"expression": "event",
"options": {
"enable": "1",
"background": "0",
"cmd": "#[Maison][R\u00e9sum\u00e9][Pluie]#",
"value": "#[Maison][R\u00e9sum\u00e9][Pluie 24h]#-variable(Pluies_24h,0)"
},
"order": "0"
},
{
"id": "3308",
"scenarioSubElement_id": "2781",
"type": "action",
"subtype": null,
"expression": "variable",
"options": {
"enable": "1",
"background": "0",
"name": "Pluies_24h",
"value": "#[Maison][R\u00e9sum\u00e9][Pluie 24h]#"
},
"order": "1"
},
{
"id": "3342",
"scenarioSubElement_id": "2781",
"type": "action",
"subtype": null,
"expression": "event",
"options": {
"enable": "1",
"background": "0",
"cmd": "#[Maison][R\u00e9sum\u00e9][Pluie Heure]#",
"value": "statisticsBetween(#[Maison][R\u00e9sum\u00e9][Pluie]#,sum,last hour,now)"
},
"order": "2"
},
{
"id": "3340",
"scenarioSubElement_id": "2781",
"type": "action",
"subtype": null,
"expression": "remove_inat",
"options": {
"enable": "1",
"background": "0"
},
"order": "3"
}
]
}
]
},
{
"id": "1081",
"name": null,
"type": "action",
"options": [],
"order": "0",
"subElements": [
{
"id": "2812",
"name": null,
"scenarioElement_id": "1081",
"type": "action",
"subtype": "action",
"options": {
"collapse": "0",
"enable": "1"
},
"order": "0",
"expressions": [
{
"id": "3344",
"scenarioSubElement_id": "2812",
"type": "action",
"subtype": null,
"expression": "event",
"options": {
"enable": "1",
"background": "0",
"cmd": "#[Maison][R\u00e9sum\u00e9][Pluie semaine]#",
"value": "statisticsBetween(#[Maison][R\u00e9sum\u00e9][Pluie]#,sum,last weeks midnight,now)"
},
"order": "0"
},
{
"id": "3746",
"scenarioSubElement_id": "2812",
"type": "element",
"subtype": null,
"expression": "1209",
"options": [],
"order": "1",
"element": {
"id": "1209",
"name": null,
"type": "if",
"options": [],
"order": "0",
"subElements": [
{
"id": "3146",
"name": null,
"scenarioElement_id": "1209",
"type": "if",
"subtype": "condition",
"options": {
"collapse": "0",
"enable": "1",
"allowRepeatCondition": "0"
},
"order": "0",
"expressions": [
{
"id": "3744",
"scenarioSubElement_id": "3146",
"type": "condition",
"subtype": null,
"expression": "#[Maison][R\u00e9sum\u00e9][Pluie semaine]# == \"\"",
"options": [],
"order": "0"
}
]
},
{
"id": "3147",
"name": null,
"scenarioElement_id": "1209",
"type": "then",
"subtype": "action",
"options": [],
"order": "1",
"expressions": [
{
"id": "3745",
"scenarioSubElement_id": "3147",
"type": "action",
"subtype": null,
"expression": "event",
"options": {
"enable": "1",
"background": "0",
"cmd": "#[Maison][R\u00e9sum\u00e9][Pluie semaine]#",
"value": "0"
},
"order": "0"
}
]
},
{
"id": "3148",
"name": null,
"scenarioElement_id": "1209",
"type": "else",
"subtype": "action",
"options": [],
"order": "2",
"expressions": []
}
]
}
},
{
"id": "3345",
"scenarioSubElement_id": "2812",
"type": "action",
"subtype": null,
"expression": "event",
"options": {
"enable": "1",
"background": "0",
"cmd": "#[Maison][R\u00e9sum\u00e9][Pluie mois]#",
"value": "statisticsBetween(#[Maison][R\u00e9sum\u00e9][Pluie]#,sum,last month midnight,now)"
},
"order": "2"
},
{
"id": "3749",
"scenarioSubElement_id": "2812",
"type": "element",
"subtype": null,
"expression": "1210",
"options": [],
"order": "3",
"element": {
"id": "1210",
"name": null,
"type": "if",
"options": [],
"order": "0",
"subElements": [
{
"id": "3149",
"name": null,
"scenarioElement_id": "1210",
"type": "if",
"subtype": "condition",
"options": {
"collapse": "0",
"enable": "1",
"allowRepeatCondition": "0"
},
"order": "0",
"expressions": [
{
"id": "3747",
"scenarioSubElement_id": "3149",
"type": "condition",
"subtype": null,
"expression": "#[Maison][R\u00e9sum\u00e9][Pluie mois]# == \"\"",
"options": [],
"order": "0"
}
]
},
{
"id": "3150",
"name": null,
"scenarioElement_id": "1210",
"type": "then",
"subtype": "action",
"options": [],
"order": "1",
"expressions": [
{
"id": "3748",
"scenarioSubElement_id": "3150",
"type": "action",
"subtype": null,
"expression": "event",
"options": {
"enable": "1",
"background": "0",
"cmd": "#[Maison][R\u00e9sum\u00e9][Pluie mois]#",
"value": "0"
},
"order": "0"
}
]
},
{
"id": "3151",
"name": null,
"scenarioElement_id": "1210",
"type": "else",
"subtype": "action",
"options": [],
"order": "2",
"expressions": []
}
]
}
},
{
"id": "3346",
"scenarioSubElement_id": "2812",
"type": "action",
"subtype": null,
"expression": "event",
"options": {
"enable": "1",
"background": "0",
"cmd": "#[Maison][R\u00e9sum\u00e9][Pluie ann\u00e9e]#",
"value": "statisticsBetween(#[Maison][R\u00e9sum\u00e9][Pluie]#,sum,last year midnight,now)"
},
"order": "4"
}
]
}
]
}
]
++