id
arry
trenner
anzahl_offen
anzahl_geschlossen
anzahl_gesamt
offene_Fenster_Liste
gesamt_Fenster_Liste
iQontrol_Fenster_Liste
idFenster
wert
htmlText
getParentName
aWYoZ2V0T2JqZWN0KGlkLnN1YnN0cmluZygwLCBpZC5sYXN0SW5kZXhPZignLicpKSkpIHJldHVybiBnZXRPYmplY3QoaWQuc3Vic3RyaW5nKDAsIGlkLmxhc3RJbmRleE9mKCcuJykpKS5jb21tb24ubmFtZTsNCmVsc2UgcmV0dXJuIG51bGw7
Beschreibe diese Funktion …
arry, trenner
cmV0dXJuIGFycnkuam9pbih0cmVubmVyKTs=
Beschreibe diese Funktion …
DP_Anzahl_Fenster_geoeffnet_geschlossen_gesamt_anlegen
Ly8jIyMjIyMjIyMjIyMjIyMjIyMjIy0tLUZlbnN0ZXIgQW56YWhsIGdlw7ZmZm5ldC1nZXNjaGxvc3Nlbi1nZXNhbXQtLS0jIyMjIyMjIyMjIyMjIyMjIyMjIwoKLy8gRGF0ZW5wdW5rdCB1bnRlciAwX3VzZXJkYXRhLjAgZXJzdGVsbGVuCmNvbnN0IGRwMDAxID0gJ0ZlbnN0ZXJfemFlaGxlbi4wMV9BbnphaGxfRmVuc3Rlcl9vZmZlbic7CmNvbnN0IGR0cDAwMSA9IHt0eXBlOiAnbnVtYmVyJywgcmVhZDogdHJ1ZSwgd3JpdGU6IGZhbHNlLCBuYW1lOiAnMDFfQW56YWhsX0ZlbnN0ZXJfb2ZmZW4nLHJvbGU6ICdudW1iZXInfTsKIApmdW5jdGlvbiBjcmVhdGVEcDAwMShpZCwgY29tbW9uKSB7CiAgICBpZigkKGlkKS5sZW5ndGgpIGxvZygnRGF0ZW5wdW5rdCAnICsgaWQgKyAnIGV4aXN0aWVydCBiZXJlaXRzICEnLCAnd2FybicpOwogICAgZWxzZSB7CiAgICAgICAgdmFyIG9iaiA9IHt9OwogICAgICAgIG9iai50eXBlID0gJ3N0YXRlJzsKICAgICAgICBvYmouY29tbW9uID0gY29tbW9u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NyZWF0ZURwMDAyKGlkLCBjb21tb24pIHsKICAgIGlmKCQoaWQpLmxlbmd0aCkgbG9nKCdEYXRlbnB1bmt0ICcgKyBpZCArICcgZXhpc3RpZXJ0IGJlcmVpdHMgIScsICd3YXJuJyk7CiAgICBlbHNlIHsKICAgICAgICB2YXIgb2JqID0ge307CiAgICAgICAgb2JqLnR5cGUgPSAnc3RhdGUnOwogICAgICAgIG9iai5jb21tb24gPSBjb21tb247CiAgICAgICAgb2JqLm5hdGl2ZSA9IHt9OwogICAgICAgIHNldE9iamVjdChpZCwgb2JqLCBmdW5jdGlvbiAoZXJyKSB7CiAgICAgICAgICAgIGlmIChlcnIpIGxvZygnQ2Fubm90IHdyaXRlIG9iamVjdDogJyArIGVycikKICAgICAgICAgICAgZWxzZSB7CiAgICAgICAgICAgICAgICB2YXIgaW5pdCA9IG51bGw7CiAgICAgICAgICAgICAgICBpZihjb21tb24uZGVmID09PSB1bmRlZmluZWQpIHsKICAgICAgICAgICAgICAgICAgICBpZihjb21tb24udHlwZSA9PT0gJ251bWJlcicpIGluaXQgPSAwOwogICAgICAgICAgICAgICAgICAgIGlmKGNvbW1vbi50eXBlID09PSAnYm9vbGVhbicpIGluaXQgPSBmYWxzZTsKICAgICAgICAgICAgICAgICAgICBpZihjb21tb24udHlwZSA9PT0gJ3N0cmluZycpIGluaXQgPSAnbm9jaCBsZWVyJzsKICAgICAgICAgICAgICAgIH0gZWxzZSBpbml0ID0gY29tbW9uLmRlZjsKICAgICAgICAgICAgICAgIHNldFRpbWVvdXQoZnVuY3Rpb24oKSB7c2V0U3RhdGUoaWQsIGluaXQsIHRydWUpO30sMTAwMCk7CiAgICAgICAgICAgIH0KICAgICAgICB9KTsKICAgIH0KfQpjcmVhdGVEcDAwMignMF91c2VyZGF0YS4wLicgKyBkcDAwMiwgZHRwMDAyKTsKCi8vIERhdGVucHVua3QgdW50ZXIgMF91c2VyZGF0YS4wIGVyc3RlbGxlbgpjb25zdCBkcDAwMyA9ICdGZW5zdGVyX3phZWhsZW4uMDNfQW56YWhsX0ZlbnN0ZXJfZ2VzYW10JzsKY29uc3QgZHRwMDAzID0ge3R5cGU6ICdudW1iZXInLCByZWFkOiB0cnVlLCB3cml0ZTogZmFsc2UsIG5hbWU6ICcwM19BbnphaGxfRmVuc3Rlcl9nZXNhbXQnLHJvbGU6ICdudW1iZXInfTsKIApmdW5jdGlvbiBjcmVhdGVEcDAwMyhpZCwgY29tbW9uKSB7CiAgICBpZigkKGlkKS5sZW5ndGgpIGxvZygnRGF0ZW5wdW5rdCAnICsgaWQgKyAnIGV4aXN0aWVydCBiZXJlaXRzICEnLCAnd2FybicpOwogICAgZWxzZSB7CiAgICAgICAgdmFyIG9iaiA9IHt9OwogICAgICAgIG9iai50eXBlID0gJ3N0YXRlJzsKICAgICAgICBvYmouY29tbW9uID0gY29tbW9uOwogICAgICAgIG9iai5uYXRpdmUgPSB7fTsKICAgICAgICBzZXRPYmplY3QoaWQsIG9iaiwgZnVuY3Rpb24gKGVycikgewogICAgICAgICAgICBpZiAoZXJyKSBsb2coJ0Nhbm5vdCB3cml0ZSBvYmplY3Q6ICcgKyBlcnIpCiAgICAgICAgICAgIGVsc2UgewogICAgICAgICAgICAgICAgdmFyIGluaXQgPSBudWxsOwogICAgICAgICAgICAgICAgaWYoY29tbW9uLmRlZiA9PT0gdW5kZWZpbmVkKSB7CiAgICAgICAgICAgICAgICAgICAgaWYoY29tbW9uLnR5cGUgPT09ICdudW1iZXInKSBpbml0ID0gMDsKICAgICAgICAgICAgICAgICAgICBpZihjb21tb24udHlwZSA9PT0gJ2Jvb2xlYW4nKSBpbml0ID0gZmFsc2U7CiAgICAgICAgICAgICAgICAgICAgaWYoY29tbW9uLnR5cGUgPT09ICdzdHJpbmcnKSBpbml0ID0gJ25vY2ggbGVlcic7CiAgICAgICAgICAgICAgICB9IGVsc2UgaW5pdCA9IGNvbW1vbi5kZWY7CiAgICAgICAgICAgICAgICBzZXRUaW1lb3V0KGZ1bmN0aW9uKCk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KICAgICAgICAgICAgICAgICAgICBpZihjb21tb24udHlwZSA9PT0gJ251bWJlcicpIGluaXQgPSAwOwogICAgICAgICAgICAgICAgICAgIGlmKGNvbW1vbi50eXBlID09PSAnYm9vbGVhbicpIGluaXQgPSBmYWxzZTsKICAgICAgICAgICAgICAgICAgICBpZihjb21tb24udHlwZSA9PT0gJ3N0cmluZycpIGluaXQgPSAnbm9jaCBsZWVyJzsKICAgICAgICAgICAgICAgIH0gZWxzZSBpbml0ID0gY29tbW9uLmRlZjsKICAgICAgICAgICAgICAgIHNldFRpbWVvdXQoZnVuY3Rpb24oKSB7c2V0U3RhdGUoaWQsIGluaXQsIHRydWUpO30sMTAwMCk7CiAgICAgICAgICAgIH0KICAgICAgICB9KTsKICAgIH0KfQpjcmVhdGVEcDAwNCgnMF91c2VyZGF0YS4wLicgKyBkcDAwNCwgZHRwMDA0KTs=
legt Datenpunkte für den die Anzahl gekippter/geöffneter/geschlossenen/gesamt Fenster an
DP_Fensterliste_mit_Zustand_anlegen
Ly8jIyMjIyMjIyMjIyMjIyMjIyMjIy0tLURQIGdlc2FtdGUgRmVuc3RlciBMaXN0ZSBtaXQgWnVzdGFuZCBhbmxlZ2VuLS0tIyMjIyMjIyMjIyMjIyMjIyMjIyMKCi8vIERhdGVucHVua3QgdW50ZXIgMF91c2VyZGF0YS4wIGVyc3RlbGxlbgpjb25zdCBkcDAwMSA9ICdGZW5zdGVyX3phZWhsZW4uMDVfZ2VzYW10ZV9GZW5zdGVyX0xpc3RlJzsKY29uc3QgZHRwMDAxID0ge3R5cGU6ICdzdHJpbmcnLCByZWFkOiB0cnVlLCB3cml0ZTogZmFsc2UsIG5hbWU6ICcwNV9nZXNhbXRlX0ZlbnN0ZXJfTGlzdGUnLHJvbGU6ICdzdHJpbmcnfTsKIApmdW5jdGlvbiBjcmVhdGVEcDAwMShpZCwgY29tbW9uKSB7CiAgICBpZigkKGlkKS5sZW5ndGgpIGxvZygnRGF0ZW5wdW5rdCAnICsgaWQgKyAnIGV4aXN0aWVydCBiZXJlaXRzICEnLCAnd2FybicpOwogICAgZWxzZSB7CiAgICAgICAgdmFyIG9iaiA9IHt9OwogICAgICAgIG9iai50eXBlID0gJ3N0YXRlJzsKICAgICAgICBvYmouY29tbW9uID0gY29tbW9uOwogICAgICAgIG9iai5uYXRpdmUgPSB7fTsKICAgICAgICBzZXRPYmplY3QoaWQsIG9iaiwgZnVuY3Rpb24gKGVycikgewogICAgICAgICAgICBpZiAoZXJyKSBsb2coJ0Nhbm5vdCB3cml0ZSBvYmplY3Q6ICcgKyBlcnIpCiAgICAgICAgICAgIGVsc2UgewogICAgICAgICAgICAgICAgdmFyIGluaXQgPSBudWxsOwogICAgICAgICAgICAgICAgaWYoY29tbW9uLmRlZiA9PT0gdW5kZWZpbmVkKSB7CiAgICAgICAgICAgICAgICAgICAgaWYoY29tbW9uLnR5cGUgPT09ICdudW1iZXInKSBpbml0ID0gMDsKICAgICAgICAgICAgICAgICAgICBpZihjb21tb24udHlwZSA9PT0gJ2Jvb2xlYW4nKSBpbml0ID0gZmFsc2U7CiAgICAgICAgICAgICAgICAgICAgaWYoY29tbW9uLnR5cGUgPT09ICdzdHJpbmcnKSBpbml0ID0gJ25vY2ggbGVlcic7CiAgICAgICAgICAgICAgICB9IGVsc2UgaW5pdCA9IGNvbW1vbi5kZWY7CiAgICAgICAgICAgICAgICBzZXRUaW1lb3V0KGZ1bmN0aW9uKCkge3NldFN0YXRlKGlkLCBpbml0LCB0cnVlKTt9LDEwMDApOwogICAgICAgICAgICB9CiAgICAgICAgfSk7CiAgICB9Cn0KY3JlYXRlRHAwMDEoJzBfdXNlcmRhdGEuMC4nICsgZHAwMDEsIGR0cDAwMSk7
legt einen DP für eine Liste aller Fenster inklusive Zustand an
DP_iQontrol_Liste_anlegen
Ly8jIyMjIyMjIyMjIyMjIyMjIyMjIy0tLUZlbnN0ZXIgTGlzdGUgaVFvbnRyb2wgYW5sZWdlbi0tLSMjIyMjIyMjIyMjIyMjIyMjIyM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gICAgICAgICB9IGVsc2UgaW5pdCA9IGNvbW1vbi5kZWY7CiAgICAgICAgICAgICAgICBzZXRUaW1lb3V0KGZ1bmN0aW9uKCkge3NldFN0YXRlKGlkLCBpbml0LCB0cnVlKTt9LDEwMDApOwogICAgICAgICAgICB9CiAgICAgICAgfSk7CiAgICB9Cn0KY3JlYXRlRHAwMDEoJzBfdXNlcmRhdGEuMC4nICsgZHAwMDEsIGR0cDAwMSk7
legt einen DP für eine html iQontrol Liste aller Fenster inklusive Zustand an
wenn wahr werden Datenpunkte angelegt
kann nach dem anlegen7ersten Blockly Start deaktiviert werden
Selektor muss auf die eigene Aufzählung angepasst werden
Beispiel hier HMIP Fenstersensoren mit STATE
ne
default
[state.id=STATE](functions='Fenster')
anzahl_offen
0
anzahl_geschlossen
0
anzahl_gesamt
0
offene_Fenster_Liste
gesamt_Fenster_Liste
iQontrol_Fenster_Liste
Selektor auf die eigene Aufzählung anpassen
idFenster
[state.id=STATE](functions='Fenster')
anzahl_gesamt
1
wert
val
idFenster
htmlText
<!DOCTYPE html><html lang="de"><head><title>Fenster</title><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body>
<p style="color:#0000FF; font-family:Helvetica; font-weight: bold">Fensterstatus</p>
<p style="color:#ff0000; font-family:Helvetica; font-weight: bold">letze Änderung:
custom
TT.MM.JJJJ SS:mm:ss
</p>
<table border="8" cellspacing="10" cellpadding="20" style="color:black; font-family:Helvetica;background-image: linear-gradient(42deg,transparent,lightblue);">
<tr style="color:#0000FF"; font-weight: bold"><td>Fenster-Türen   </td><td>Status</td></tr>
<tr><td>
OR
NEQ
wert
0
EQ
wert
TRUE
anzahl_offen
1
INSERT
LAST
offene_Fenster_Liste
idFenster
geöffnet
INSERT
LAST
gesamt_Fenster_Liste
idFenster
:geöffnet
INSERT
LAST
iQontrol_Fenster_Liste
idFenster
<td><span style="color:#FF0000"> geöffnet </span>
OR
EQ
wert
0
EQ
wert
FALSE
anzahl_geschlossen
1
INSERT
LAST
gesamt_Fenster_Liste
idFenster
:geschlossen
INSERT
FIRST
iQontrol_Fenster_Liste
idFenster
<td>geschlossen
0_userdata.0.Fenster_zaehlen.01_Anzahl_Fenster_offen
FALSE
anzahl_offen
0_userdata.0.Fenster_zaehlen.02_Anzahl_Fenster_geschlossen
FALSE
anzahl_geschlossen
0_userdata.0.Fenster_zaehlen.03_Anzahl_Fenster_gesamt
FALSE
anzahl_gesamt
0_userdata.0.Fenster_zaehlen.04_offene_Fenster_Liste
FALSE
offene_Fenster_Liste
EQ
offene_Fenster_Liste
0_userdata.0.Fenster_zaehlen.04_offene_Fenster_Liste
FALSE
Aktuell sind alle Fenster oder Türen geschlossen.
0_userdata.0.Fenster_zaehlen.05_gesamte_Fenster_Liste
FALSE
gesamt_Fenster_Liste
0_userdata.0.Fenster_zaehlen.06_iQontrol_Fenster_Liste
FALSE
htmlText
TEXT
1
iQontrol_Fenster_Liste
<tr><td>
</table></body>