Hallo,
irgendwie habe ich Stundenlang das Menü nach besten Wissen und Gewissen nachgebaut... Aber irgendwas scheint einfach nicht zu funktionieren.
Die Telegram "Antworten" sind vertauscht und nur ab und zu gibt es eine gescheite Antwort.
Das Aufteilen der Nachrichten funktioniert sehr gut. Auch bekommt nur TSDChris die Antwort. Die "anderen" bleiben Tot.
Es geht darum, dass Admin "TSDChris" ein umfangreiches Menü hat und die Mitarbeiter die abgespeckte Version.
Ebenso soll nur der Absender des Befehls eine Antwort erhalten.
Bitte um Hilfe
<xml xmlns="https://developers.google.com/blockly/xml">
<variables>
<variable id="F3=hz[F+,2ia@~(=Ya+v">Telegram_Text</variable>
<variable id="uPqi3lp)VdQ!efz^2S5A">Telegram_Empfaenger</variable>
<variable id="FfcoZ%/u`|i@M=B.6VE7">Menue_Uebersicht_empfaenger</variable>
<variable id="o4Cw37sYQKkEiK:B2(AL">Letzter_Absender</variable>
<variable id="vk!u4r$n@OTSq0C@P*Li">Letzter_Text</variable>
<variable id="ghkwc7a[ajcllnEmNEH[">Letzter_Text_klein</variable>
</variables>
<block type="procedures_defnoreturn" id="I,ffplEW+H#1ahx97man" x="612" y="463">
<mutation>
<arg name="Telegram_Text" varid="F3=hz[F+,2ia@~(=Ya+v"></arg>
<arg name="Telegram_Empfaenger" varid="uPqi3lp)VdQ!efz^2S5A"></arg>
</mutation>
<field name="NAME">Telegram senden</field>
<comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment>
<statement name="STACK">
<block type="telegram" id="F63QM30Px%PhXuL$QSlT">
<field name="INSTANCE"></field>
<field name="LOG"></field>
<field name="SILENT">FALSE</field>
<field name="PARSEMODE">default</field>
<value name="MESSAGE">
<shadow xmlns="http://www.w3.org/1999/xhtml" type="text">
<field name="TEXT">text</field>
</shadow>
<block type="variables_get" id=".~aFu.2_2I~T0%Z~![IM">
<field name="VAR" id="F3=hz[F+,2ia@~(=Ya+v">Telegram_Text</field>
</block>
</value>
<value name="USERNAME">
<block type="variables_get" id="yi(7[Cnjx5;pcUg0=4Fo">
<field name="VAR" id="uPqi3lp)VdQ!efz^2S5A">Telegram_Empfaenger</field>
</block>
</value>
</block>
</statement>
</block>
<block type="on_ext" id=")7/BKKYy8C`y[sxObudf" x="-337" y="588">
<mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
<field name="CONDITION">ne</field>
<field name="ACK_CONDITION"></field>
<value name="OID0">
<shadow type="field_oid" id="IMoTQ4~}9,4U.(INq6+w">
<field name="oid">telegram.0.communicate.request</field>
</shadow>
</value>
<statement name="STATEMENT">
<block type="variables_set" id="PanOm:|,arAk6KJ.T]]W">
<field name="VAR" id="o4Cw37sYQKkEiK:B2(AL">Letzter_Absender</field>
<value name="VALUE">
<block type="get_value" id="}Zl@ZS{OrRLS~3TsqDQo">
<field name="ATTR">val</field>
<field name="OID">0_userdata.0.Telegram.NachrichtAufteilen.BenutzerTelegram</field>
</block>
</value>
<next>
<block type="variables_set" id="AQ_=i3JUUf#8b1(y+:NH">
<field name="VAR" id="vk!u4r$n@OTSq0C@P*Li">Letzter_Text</field>
<value name="VALUE">
<block type="get_value" id="EV3Zl/kZq00Uu8i1yuMx">
<field name="ATTR">val</field>
<field name="OID">0_userdata.0.Telegram.NachrichtAufteilen.NachrichtTelegram</field>
</block>
</value>
<next>
<block type="controls_if" id="i4Ab?~fyAj$]tfff7@%)">
<value name="IF0">
<block type="logic_operation" id="MDW)2DU*].52N:KUK:09" inline="false">
<field name="OP">AND</field>
<value name="A">
<block type="logic_compare" id="U/Y2;)Lat|3blk$YxLC=">
<field name="OP">EQ</field>
<value name="A">
<block type="variables_get" id="o?(T*IqtI8wbzrsoV^9L">
<field name="VAR" id="o4Cw37sYQKkEiK:B2(AL">Letzter_Absender</field>
</block>
</value>
<value name="B">
<block type="text" id="qDnxSb*VdJE{~Bo2(m$+">
<field name="TEXT">TSDChris</field>
</block>
</value>
</block>
</value>
<value name="B">
<block type="logic_compare" id="1I#8`L{Z~U]*5O0~A[Bi">
<field name="OP">EQ</field>
<value name="A">
<block type="variables_get" id="wl*Y/18!iRs2mT|9*e?l">
<field name="VAR" id="ghkwc7a[ajcllnEmNEH[">Letzter_Text_klein</field>
</block>
</value>
<value name="B">
<block type="text" id="^=efYJi/H{q2?vgn3wT0">
<field name="TEXT">Übersicht</field>
</block>
</value>
</block>
</value>
</block>
</value>
<statement name="DO0">
<block type="procedures_callcustomnoreturn" id="=K]~1_(+qmzFKYrzkn3F">
<mutation name="Menue_Uebersicht_Chris">
<arg name="Menue_Uebersicht_empfaenger"></arg>
</mutation>
<value name="ARG0">
<block type="variables_get" id="X8;U(BD*v]//DWcU:HO/">
<field name="VAR" id="o4Cw37sYQKkEiK:B2(AL">Letzter_Absender</field>
</block>
</value>
</block>
</statement>
<next>
<block type="controls_if" id="DX,5d:N:QJJ7~,juf2P$">
<value name="IF0">
<block type="logic_operation" id="{wzM?L1by-Q|*rC3;vuD" inline="false">
<field name="OP">AND</field>
<value name="A">
<block type="logic_compare" id="5#xkJ[ypS[x457pCb.`p">
<field name="OP">EQ</field>
<value name="A">
<block type="variables_get" id="T5b).W?Qv1{+ApGI|awX">
<field name="VAR" id="o4Cw37sYQKkEiK:B2(AL">Letzter_Absender</field>
</block>
</value>
<value name="B">
<block type="text" id="JOiG)|KH}O6Aaro^EbVr">
<field name="TEXT">TSDChris</field>
</block>
</value>
</block>
</value>
<value name="B">
<block type="logic_compare" id="AAe?+#3f7y!WD=a_N$|5">
<field name="OP">EQ</field>
<value name="A">
<block type="variables_get" id=";.@i5F$|X}|SQ/FL{V{#">
<field name="VAR" id="vk!u4r$n@OTSq0C@P*Li">Letzter_Text</field>
</block>
</value>
<value name="B">
<block type="text" id="c[}cwuNo]-PH-YrCm:vA">
<field name="TEXT">Temperatursensoren</field>
</block>
</value>
</block>
</value>
</block>
</value>
<statement name="DO0">
<block type="telegram" id="j%mwz1CkI-0C[QOXq~Oc">
<field name="INSTANCE"></field>
<field name="LOG"></field>
<field name="SILENT">FALSE</field>
<field name="PARSEMODE">default</field>
<value name="MESSAGE">
<shadow type="text" id="WX0IUfI2!}TcuGjVQ=!A">
<field name="TEXT">text</field>
</shadow>
<block type="text_join" id="Jb9Z$zjZaJB@r%dM@G+A">
<mutation items="2"></mutation>
<value name="ADD0">
<block type="get_value" id="4wl.C=p1g~Z0]F$z/iw(">
<field name="ATTR">val</field>
<field name="OID">zigbee.0.00158d0004a986bf.temperature</field>
</block>
</value>
<value name="ADD1">
<block type="get_value" id="ds|aZD*iwxm[yjkH0NS|">
<field name="ATTR">val</field>
<field name="OID">zigbee.0.00158d0004a988bd.temperature</field>
</block>
</value>
</block>
</value>
<value name="USERNAME">
<block type="variables_get" id="Sb(~a4xByc;x:+aG3%E4">
<field name="VAR" id="o4Cw37sYQKkEiK:B2(AL">Letzter_Absender</field>
</block>
</value>
</block>
</statement>
<next>
<block type="controls_if" id="nMi`DP]D]vd}N#V7NqA4">
<value name="IF0">
<block type="logic_operation" id="TRdgWA..u{vk|hXS%TD%" inline="false">
<field name="OP">AND</field>
<value name="A">
<block type="logic_compare" id="3:jk.?Af~bx;iA3;xn+^">
<field name="OP">EQ</field>
<value name="A">
<block type="variables_get" id="u64*b7;QraAU*GARGHg{">
<field name="VAR" id="o4Cw37sYQKkEiK:B2(AL">Letzter_Absender</field>
</block>
</value>
<value name="B">
<block type="text" id=")9v*L*_z0?y6EDrtr9z#">
<field name="TEXT">Chris</field>
</block>
</value>
</block>
</value>
<value name="B">
<block type="logic_compare" id="9XS:b4;PiGNXyT-x52DI">
<field name="OP">EQ</field>
<value name="A">
<block type="variables_get" id="VBy[F;2gA~=Ho0XcuBS/">
<field name="VAR" id="vk!u4r$n@OTSq0C@P*Li">Letzter_Text</field>
</block>
</value>
<value name="B">
<block type="text" id="!dZ?W=*Ax[TFav-AW-f2">
<field name="TEXT">Übersicht</field>
</block>
</value>
</block>
</value>
</block>
</value>
<statement name="DO0">
<block type="procedures_callcustomnoreturn" id="Lo[32vd,V~oTA:_35MOy">
<mutation name="Menue_Uebersicht_Mitarbeiter">
<arg name="Menue_Uebersicht_empfaenger"></arg>
</mutation>
<value name="ARG0">
<block type="variables_get" id="v^$.JcCehpXYs:xCn17z">
<field name="VAR" id="o4Cw37sYQKkEiK:B2(AL">Letzter_Absender</field>
</block>
</value>
</block>
</statement>
<next>
<block type="controls_if" id="L(OHYn~t!.A.LyTc^d-a">
<value name="IF0">
<block type="logic_operation" id="4r4!7KODQt8QB:jt:9o`" inline="false">
<field name="OP">AND</field>
<value name="A">
<block type="logic_compare" id="gl]a.6bKh%=U|^)M.X|P">
<field name="OP">EQ</field>
<value name="A">
<block type="variables_get" id="AA}#Ebw)yn@8%WfL3T70">
<field name="VAR" id="o4Cw37sYQKkEiK:B2(AL">Letzter_Absender</field>
</block>
</value>
<value name="B">
<block type="text" id="cuWi0YVO~)m@$=#8q5:O">
<field name="TEXT">TSDChris</field>
</block>
</value>
</block>
</value>
<value name="B">
<block type="logic_compare" id="M#ziEZ|XTxBW9y(E|Cn`">
<field name="OP">EQ</field>
<value name="A">
<block type="variables_get" id="f@fUPCdsQPK]WRI|J*B/">
<field name="VAR" id="vk!u4r$n@OTSq0C@P*Li">Letzter_Text</field>
</block>
</value>
<value name="B">
<block type="text" id="[A:-eG:z2:4Qdr#G1RFk">
<field name="TEXT">Stromverbrauch</field>
</block>
</value>
</block>
</value>
</block>
</value>
<statement name="DO0">
<block type="telegram" id="Uh#YgYoj$V?igN=nj/[6">
<field name="INSTANCE"></field>
<field name="LOG"></field>
<field name="SILENT">FALSE</field>
<field name="PARSEMODE">default</field>
<value name="MESSAGE">
<shadow type="text">
<field name="TEXT">text</field>
</shadow>
<block type="text_join" id="_~QWFLMyP+_ze}%{gX3$">
<mutation items="2"></mutation>
<value name="ADD0">
<block type="get_value" id="{N@H;pHqOB!q(+PBFasG">
<field name="ATTR">val</field>
<field name="OID">0_userdata.0.AktuellerStromverbrauch</field>
</block>
</value>
<value name="ADD1">
<block type="text" id=")~B(a3eVo-ed5`32};FB">
<field name="TEXT"> Watt</field>
</block>
</value>
</block>
</value>
<value name="USERNAME">
<block type="variables_get" id="seoLNSbw{@~4Mz}|8k0l">
<field name="VAR" id="o4Cw37sYQKkEiK:B2(AL">Letzter_Absender</field>
</block>
</value>
</block>
</statement>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</statement>
</block>
<block type="procedures_defcustomnoreturn" id="(]3%hFQzO4AX6%?+BoS." inline="false" x="613" y="662">
<mutation statements="false">
<arg name="Menue_Uebersicht_empfaenger" varid="FfcoZ%/u`|i@M=B.6VE7"></arg>
</mutation>
<field name="NAME">Menue_Uebersicht_Chris</field>
<field name="SCRIPT">c2VuZFRvKCd0ZWxlZ3JhbS4wJywgew0KICAgICAgICB1c2VyOiAoTWVudWVfVWViZXJzaWNodF9lbXBmYWVuZ2VyKSwNCiAgICB0ZXh0OiAgJ0JpdHRlIHfDpGhsZW4nLA0KICAgIHJlcGx5X21hcmt1cDogew0KICAgIGtleWJvYXJkOiBbDQogICAgICAgICAgICBbJ0dyb8OfZXIgU2FhbCBBbicsICdHcm/Dn2VyIFNhYWwgQXVzJywgJ0dyb8OfZXIgU2FhbCBEaW1tZW4nXSwNCiAgICAgICAgICAgIFsnS2xlaW5lciBTYWFsIEFuJywgJ0tsZWluZXIgU2FhbCBBdXMnLCAnS2xlaW5lciBTYWFsIERpbW1lbiddLA0KICAgICAgICAgICAgWyfDnGJlcnNpY2h0JywgJ1RlbXBlcmF0dXJzZW5zb3JlbicsICdTdHJvbXZlcmJyYXVjaCddLA0KDQogICAgICAgIF0sDQogICAgICAgIHJlc2l6ZV9rZXlib2FyZDogICB0cnVlLA0KICAgICAgICBvbmVfdGltZV9rZXlib2FyZDogdHJ1ZQ0KICAgIH0NCn0pOw==</field>
<comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment>
</block>
<block type="procedures_defcustomnoreturn" id=":{2j0}*I@K?v^_X6$t+." inline="false" x="613" y="737">
<mutation statements="false">
<arg name="Menue_Uebersicht_empfaenger" varid="FfcoZ%/u`|i@M=B.6VE7"></arg>
</mutation>
<field name="NAME">Menue_Uebersicht_Mitarbeiter</field>
<field name="SCRIPT">c2VuZFRvKCd0ZWxlZ3JhbS4wJywgew0KICAgICAgICB1c2VyOiAoTWVudWVfVWViZXJzaWNodF9lbXBmYWVuZ2VyKSwNCiAgICB0ZXh0OiAgJ0JpdHRlIHfDpGhsZW4nLA0KICAgIHJlcGx5X21hcmt1cDogew0KICAgIGtleWJvYXJkOiBbDQogICAgICAgICAgICBbJ0dyb8OfZXIgU2FhbCBBbicsICdHcm/Dn2VyIFNhYWwgQXVzJywgJ0dyb8OfZXIgU2FhbCBEaW1tZW4nXSwNCiAgICAgICAgICAgIFsnS2xlaW5lciBTYWFsIEFuJywgJ0tsZWluZXIgU2FhbCBBdXMnLCAnS2xlaW5lciBTYWFsIERpbW1lbiddLA0KICAgICAgICAgICAgWyfDnGJlcnNpY2h0JywgJ1RlbXBlcmF0dXJzZW5zb3JlbicsICdBdXRzY2gnXSwNCg0KICAgICAgICBdLA0KICAgICAgICByZXNpemVfa2V5Ym9hcmQ6ICAgdHJ1ZSwNCiAgICAgICAgb25lX3RpbWVfa2V5Ym9hcmQ6IHRydWUNCiAgICB9DQp9KTs=</field>
<comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment>
</block>
</xml>