Skip to content
  • Recent
  • Tags
  • 0 Unread 0
  • Categories
  • Unreplied
  • Popular
  • GitHub
  • Docu
  • Hilfe
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Logo
  1. ioBroker Community Home
  2. Deutsch
  3. Visualisierung
  4. Jarvis v3 Popup möglich?

NEWS

  • Wartung am 15.11. – Forum ab 22:00 Uhr nicht erreichbar
    BluefoxB
    Bluefox
    11
    2
    228

  • UPDATE 31.10.: Amazon Alexa - ioBroker Skill läuft aus ?
    apollon77A
    apollon77
    48
    3
    8.0k

  • Monatsrückblick – September 2025
    BluefoxB
    Bluefox
    13
    1
    1.7k

Jarvis v3 Popup möglich?

Jarvis v3 Popup möglich?

Scheduled Pinned Locked Moved Visualisierung
17 Posts 3 Posters 1.1k Views 4 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Renegade 0
    wrote on last edited by
    #1

    Hallo,

    ich nutze Jarvis und bin soweit recht zufrieden damit. Gibt es bei dieser Visualisierung eine Möglichkeit, wenn jemand an der Haustür klingelt den screenshot der Kamera in Jarvis als Popup zu bringen? Am besten im Popup noch einen Button für Türe öffnen.
    Ich habe auch die pro Version und notifications. Nur die muss man ja erst anklicken. Es soll automatisch aufgehen.

    mfG

    1 Reply Last reply
    0
    • M Offline
      M Offline
      MCU
      wrote on last edited by MCU
      #2

      @renegade-0 Wieso muss man die Notification erst anklicken?
      Die Notification wird je nach Einstellung direkt mit der eingestellten Zeit angezeigt.

      https://mcuiobroker.gitbook.io/jarvis-infos/jarvis/besonderheiten-v3/notifications-pro

      NUC i7 64GB mit Proxmox ---- https://mcuiobroker.gitbook.io/jarvis-infos/ Aktualisierungen der Doku auf Instagram verfolgen -> https://www.instagram.com/mcuiobroker
      Wenn Euch mein Vorschlag geholfen hat, bitte rechts "^" klicken.

      R 1 Reply Last reply
      0
      • M MCU

        @renegade-0 Wieso muss man die Notification erst anklicken?
        Die Notification wird je nach Einstellung direkt mit der eingestellten Zeit angezeigt.

        https://mcuiobroker.gitbook.io/jarvis-infos/jarvis/besonderheiten-v3/notifications-pro

        R Offline
        R Offline
        Renegade 0
        wrote on last edited by
        #3

        @mcu

        Ok, das funktioniert schon mal. Gibt es auch eine Möglichkeit, ein Bild oder ein Video/Stream in der Notification anzuzeigen?

        M 1 Reply Last reply
        0
        • R Renegade 0

          @mcu

          Ok, das funktioniert schon mal. Gibt es auch eine Möglichkeit, ein Bild oder ein Video/Stream in der Notification anzuzeigen?

          M Offline
          M Offline
          MCU
          wrote on last edited by MCU
          #4

          @renegade-0 Ist doch in der Doku beschrieben. Welches Bild soll es denn sein?
          ade812d8-96ea-4e95-8952-cda755281418-image.png

          NUC i7 64GB mit Proxmox ---- https://mcuiobroker.gitbook.io/jarvis-infos/ Aktualisierungen der Doku auf Instagram verfolgen -> https://www.instagram.com/mcuiobroker
          Wenn Euch mein Vorschlag geholfen hat, bitte rechts "^" klicken.

          R 1 Reply Last reply
          0
          • M MCU

            @renegade-0 Ist doch in der Doku beschrieben. Welches Bild soll es denn sein?
            ade812d8-96ea-4e95-8952-cda755281418-image.png

            R Offline
            R Offline
            Renegade 0
            wrote on last edited by Renegade 0
            #5

            @mcu

            habe einen Snapshot von meiner Türklingel im Jpg Format. Diesen würde ich gerne direkt anzeigen lassen.
            Kapier die Anleitung irgendwie nicht so ganz.

            {
              "title":"Testpopup", "message":"http://SmartBox:8082/state/ring.0.doorbell_195255640.Snapshot.jpg", "state": "unread", "criticality":"info", "display":"popup"
            }
            

            jarvis_popup.PNG

            Anstatt dem Link soll da das Bild zu sehen sein und am besten unten 3 Buttons. OK(=Löschen), Live-Ansicht(Weiterleitung) und Tür öffnen(STATE setzen).

            Also das wäre das Optimum.

            M 1 Reply Last reply
            0
            • R Renegade 0

              @mcu

              habe einen Snapshot von meiner Türklingel im Jpg Format. Diesen würde ich gerne direkt anzeigen lassen.
              Kapier die Anleitung irgendwie nicht so ganz.

              {
                "title":"Testpopup", "message":"http://SmartBox:8082/state/ring.0.doorbell_195255640.Snapshot.jpg", "state": "unread", "criticality":"info", "display":"popup"
              }
              

              jarvis_popup.PNG

              Anstatt dem Link soll da das Bild zu sehen sein und am besten unten 3 Buttons. OK(=Löschen), Live-Ansicht(Weiterleitung) und Tür öffnen(STATE setzen).

              Also das wäre das Optimum.

              M Offline
              M Offline
              MCU
              wrote on last edited by
              #6

              @renegade-0 Welches Programm nutzt du denn für die Erstellung von der Notification?

              NUC i7 64GB mit Proxmox ---- https://mcuiobroker.gitbook.io/jarvis-infos/ Aktualisierungen der Doku auf Instagram verfolgen -> https://www.instagram.com/mcuiobroker
              Wenn Euch mein Vorschlag geholfen hat, bitte rechts "^" klicken.

              R 1 Reply Last reply
              0
              • M MCU

                @renegade-0 Welches Programm nutzt du denn für die Erstellung von der Notification?

                R Offline
                R Offline
                Renegade 0
                wrote on last edited by
                #7

                @mcu
                node-red

                M 1 Reply Last reply
                0
                • R Renegade 0

                  @mcu
                  node-red

                  M Offline
                  M Offline
                  MCU
                  wrote on last edited by
                  #8

                  @renegade-0 Dann musst du das noch mit rein nehmen.

                  httpAdr = "http://SmartBox:8082/state/ring.0.doorbell_195255640.Snapshot.jpg";
                  httpAdr = httpAdr.replace('"',"%22");
                  httpAdr = httpAdr.replace('"',"%22");
                  jarvisNotify.message= '<iFrame src='+ String(httpAdr) +' height="350" width="350" scroll=true after height="400"></iFrame>';
                  

                  NUC i7 64GB mit Proxmox ---- https://mcuiobroker.gitbook.io/jarvis-infos/ Aktualisierungen der Doku auf Instagram verfolgen -> https://www.instagram.com/mcuiobroker
                  Wenn Euch mein Vorschlag geholfen hat, bitte rechts "^" klicken.

                  R 1 Reply Last reply
                  0
                  • M MCU

                    @renegade-0 Dann musst du das noch mit rein nehmen.

                    httpAdr = "http://SmartBox:8082/state/ring.0.doorbell_195255640.Snapshot.jpg";
                    httpAdr = httpAdr.replace('"',"%22");
                    httpAdr = httpAdr.replace('"',"%22");
                    jarvisNotify.message= '<iFrame src='+ String(httpAdr) +' height="350" width="350" scroll=true after height="400"></iFrame>';
                    
                    R Offline
                    R Offline
                    Renegade 0
                    wrote on last edited by
                    #9

                    @mcu sagte in Jarvis v3 Popup möglich?:

                    @renegade-0 Dann musst du das noch mit rein nehmen.

                    Einfach in die {} mit rein nehmen und in add notification schreiben haut nicht hin. Wie genau geht das denn?

                    M 1 Reply Last reply
                    0
                    • R Renegade 0

                      @mcu sagte in Jarvis v3 Popup möglich?:

                      @renegade-0 Dann musst du das noch mit rein nehmen.

                      Einfach in die {} mit rein nehmen und in add notification schreiben haut nicht hin. Wie genau geht das denn?

                      M Offline
                      M Offline
                      MCU
                      wrote on last edited by MCU
                      #10

                      @renegade-0 Zeig mal bitte das Programm. Also die Umsetzung, mit der du in die addNotification rein schreibst.

                      NUC i7 64GB mit Proxmox ---- https://mcuiobroker.gitbook.io/jarvis-infos/ Aktualisierungen der Doku auf Instagram verfolgen -> https://www.instagram.com/mcuiobroker
                      Wenn Euch mein Vorschlag geholfen hat, bitte rechts "^" klicken.

                      1 Reply Last reply
                      0
                      • R Offline
                        R Offline
                        Renegade 0
                        wrote on last edited by Renegade 0
                        #11

                        @mcu
                        Noch gibt es das nicht. aktuell versuche ich mir noch den passenden String zu basteln, den ich dann in addNotification schreiben kann. Zum testen setze ich den String manuell ein.

                        Würde es aber mit einer ioBroker out machen.

                        M 1 Reply Last reply
                        0
                        • R Renegade 0

                          @mcu
                          Noch gibt es das nicht. aktuell versuche ich mir noch den passenden String zu basteln, den ich dann in addNotification schreiben kann. Zum testen setze ich den String manuell ein.

                          Würde es aber mit einer ioBroker out machen.

                          M Offline
                          M Offline
                          MCU
                          wrote on last edited by
                          #12

                          @renegade-0
                          Vielleicht kann @mickym dir helfen, ich kenne mich mit node-red gar nicht aus.
                          https://mcuiobroker.gitbook.io/jarvis-infos/jarvis/besonderheiten-v3/notifications-pro/synology-bild

                          @mickym : Bitte so erklären, dass ich es in die Doku mit aufnehmen kann. Vielen Dank.

                          NUC i7 64GB mit Proxmox ---- https://mcuiobroker.gitbook.io/jarvis-infos/ Aktualisierungen der Doku auf Instagram verfolgen -> https://www.instagram.com/mcuiobroker
                          Wenn Euch mein Vorschlag geholfen hat, bitte rechts "^" klicken.

                          R mickymM 2 Replies Last reply
                          0
                          • M MCU

                            @renegade-0
                            Vielleicht kann @mickym dir helfen, ich kenne mich mit node-red gar nicht aus.
                            https://mcuiobroker.gitbook.io/jarvis-infos/jarvis/besonderheiten-v3/notifications-pro/synology-bild

                            @mickym : Bitte so erklären, dass ich es in die Doku mit aufnehmen kann. Vielen Dank.

                            R Offline
                            R Offline
                            Renegade 0
                            wrote on last edited by
                            #13

                            @mcu

                            Ich brauche eigentlich nur den String, den ich manuell einfügen kann. WEnn ich es mit einem fertigen Stringg manuell hinbekomme, kann ich mir diesen dann in node-red nachbauen.

                            1 Reply Last reply
                            0
                            • M MCU

                              @renegade-0
                              Vielleicht kann @mickym dir helfen, ich kenne mich mit node-red gar nicht aus.
                              https://mcuiobroker.gitbook.io/jarvis-infos/jarvis/besonderheiten-v3/notifications-pro/synology-bild

                              @mickym : Bitte so erklären, dass ich es in die Doku mit aufnehmen kann. Vielen Dank.

                              mickymM Offline
                              mickymM Offline
                              mickym
                              Most Active
                              wrote on last edited by mickym
                              #14

                              @mcu sagte in Jarvis v3 Popup möglich?:

                              @renegade-0
                              Vielleicht kann @mickym dir helfen, ich kenne mich mit node-red gar nicht aus.
                              https://mcuiobroker.gitbook.io/jarvis-infos/jarvis/besonderheiten-v3/notifications-pro/synology-bild

                              @mickym : Bitte so erklären, dass ich es in die Doku mit aufnehmen kann. Vielen Dank.

                              Nun ich hab einfach Deinen Code mit dem Link in eine function Node kopiert - man kann das nun natürlich auch ohne die function Node machen:

                              Sprich das Objekt, dass @Renegade-0 in sein Objekt kopieren will ist einfach das hier:

                              {
                                "title": "Es hat geklingelt",
                                "message": "<iFrame src=https://www.iobroker.net/de/media/iobroker-simple-overview.png height=\"350\" width=\"350\" scroll=true after height=\"400\"></iFrame>",
                                "state": "unread",
                                "criticality": "none",
                                "display": "popup",
                                "timeout": 180000,
                                "snackbarOrigin": {},
                                "icon": "bell-ring-outline",
                                "iconColor": "#5D5DED",
                                "backgroundColor": "black",
                                "fontColor": "white",
                                "focusTab": ""
                              }
                              

                              Ich hab aber einfach, dass was Du in dem Code machst verwendest und in eine function Node kopiert:

                              Das einzige was ich geändert habe ist, dass man das Auslesen des Datenpunktes mit der URL zu dem Bild im Flow nun vorgelagert ist und das Objekt nicht im Code stringifiziert wird, damit man ggf. noch was ändern kann. 😉

                              7ded7a92-e417-4c72-af23-f6d13c22cba4-image.png

                              Dein Code bleibt also nahezu unverändert in der function Node:

                              3c777926-5b91-43d3-b32e-6d5a78f010e2-image.png

                              Hier der Flow zum Import:

                              [
                                 {
                                     "id": "5ef0a4478036e523",
                                     "type": "function",
                                     "z": "cacb47b4dea2692d",
                                     "name": "Synology-Bild in der Notification",
                                     "func": "var jarvisNotify = {};\n//Beispiele\njarvisNotify.title = \"Es hat geklingelt\";\n// \"<b>Dies ist BOLD</b>\"\n// let httpAdr = getState('synology.0.SurveillanceStation.cameras.Eingang.linkMjpegHttpPath').val;\nlet httpAdr = msg.httpAdr;\n\nhttpAdr = httpAdr.replace('\"', \"%22\");\nhttpAdr = httpAdr.replace('\"', \"%22\");\njarvisNotify.message = '<iFrame src=' + String(httpAdr) + ' height=\"350\" width=\"350\" scroll=true after height=\"400\"></iFrame>';\n\njarvisNotify.state = \"unread\";          //Damit bleibt die Benachrichtigung auch nach POPUP ungelesen und wird oben angezeigt mit der Zahl\njarvisNotify.criticality = \"none\";      // error,warning,info,success\njarvisNotify.display = \"popup\";          //drawer,snackbar,popup, none für focusTab\njarvisNotify.timeout = 180000;  //5000ms -> 5 Sekunden\njarvisNotify.snackbarOrigin = {};       //\"snackbarOrigin\": { \"horizontal\": \"...\", \"vertical\": \"\" }, \n// optional, applies when display is snackbar, { horizontal: 'center' | 'left' | 'right', vertical: 'bottom' | 'top' }\njarvisNotify.icon = \"bell-ring-outline\"; //mdi Iconify\njarvisNotify.iconColor = \"#5D5DED\";\njarvisNotify.backgroundColor = \"black\";\njarvisNotify.fontColor = \"white\";\njarvisNotify.focusTab = \"\"; //focus a certain tab\n\n// setState('jarvis.0.addNotification', JSON.stringify(jarvisNotify));\nmsg.payload = jarvisNotify;\nreturn msg;",
                                     "outputs": 1,
                                     "noerr": 0,
                                     "initialize": "",
                                     "finalize": "",
                                     "libs": [],
                                     "x": 550,
                                     "y": 340,
                                     "wires": [
                                         [
                                             "5df0cada653f60d3",
                                             "c05c57a32531b7a7"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "425bdd8b537b499f",
                                     "type": "ioBroker get",
                                     "z": "cacb47b4dea2692d",
                                     "name": "httpAdr",
                                     "topic": "0_userdata.0.Test.url",
                                     "attrname": "httpAdr",
                                     "payloadType": "value",
                                     "errOnInvalidState": "nothing",
                                     "x": 320,
                                     "y": 340,
                                     "wires": [
                                         [
                                             "5ef0a4478036e523"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "0cc18f9ac32e84f6",
                                     "type": "inject",
                                     "z": "cacb47b4dea2692d",
                                     "name": "",
                                     "props": [
                                         {
                                             "p": "trigger",
                                             "v": "true",
                                             "vt": "bool"
                                         }
                                     ],
                                     "repeat": "",
                                     "crontab": "",
                                     "once": false,
                                     "onceDelay": 0.1,
                                     "topic": "",
                                     "x": 170,
                                     "y": 340,
                                     "wires": [
                                         [
                                             "425bdd8b537b499f"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "5df0cada653f60d3",
                                     "type": "debug",
                                     "z": "cacb47b4dea2692d",
                                     "name": "Jarvis Notification Objekt",
                                     "active": true,
                                     "tosidebar": true,
                                     "console": false,
                                     "tostatus": false,
                                     "complete": "payload",
                                     "targetType": "msg",
                                     "statusVal": "",
                                     "statusType": "auto",
                                     "x": 810,
                                     "y": 400,
                                     "wires": []
                                 },
                                 {
                                     "id": "2334bd2f27160450",
                                     "type": "ioBroker out",
                                     "z": "cacb47b4dea2692d",
                                     "name": "",
                                     "topic": "jarvis.0.addNotification",
                                     "ack": "false",
                                     "autoCreate": "false",
                                     "stateName": "",
                                     "role": "",
                                     "payloadType": "",
                                     "readonly": "",
                                     "stateUnit": "",
                                     "stateMin": "",
                                     "stateMax": "",
                                     "x": 1000,
                                     "y": 340,
                                     "wires": []
                                 },
                                 {
                                     "id": "c05c57a32531b7a7",
                                     "type": "json",
                                     "z": "cacb47b4dea2692d",
                                     "name": "",
                                     "property": "payload",
                                     "action": "",
                                     "pretty": false,
                                     "x": 770,
                                     "y": 340,
                                     "wires": [
                                         [
                                             "2334bd2f27160450",
                                             "aa76732d72377616"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "aa76732d72377616",
                                     "type": "debug",
                                     "z": "cacb47b4dea2692d",
                                     "name": "Stringified ;)",
                                     "active": true,
                                     "tosidebar": true,
                                     "console": false,
                                     "tostatus": false,
                                     "complete": "payload",
                                     "targetType": "msg",
                                     "statusVal": "",
                                     "statusType": "auto",
                                     "x": 970,
                                     "y": 300,
                                     "wires": []
                                 }
                              ]
                              

                              Für die Doku langt es dieses Objekt von oben vorzugeben, das Parmetrisieren müssen die Leute innerhalb von NR selbst machen:

                              9ff10e63-85ef-41e1-b01b-6a6d11c55306-image.png

                              [
                                 {
                                     "id": "0be55e6a34d1b37b",
                                     "type": "change",
                                     "z": "cacb47b4dea2692d",
                                     "name": "Jarvis Notification Objekt",
                                     "rules": [
                                         {
                                             "t": "set",
                                             "p": "payload",
                                             "pt": "msg",
                                             "to": "{\t   \"title\":\"Es hat geklingelt\",\t   \"message\":payload,\t   \"state\":\"unread\",\t   \"criticality\":\"none\",\t   \"display\":\"popup\",\t   \"timeout\":180000,\t   \"snackbarOrigin\":{},\t   \"icon\":\"bell-ring-outline\",\t   \"iconColor\":\"#5D5DED\",\t   \"backgroundColor\":\"black\",\t   \"fontColor\":\"white\",\t   \"focusTab\":\"\"\t}",
                                             "tot": "jsonata"
                                         }
                                     ],
                                     "action": "",
                                     "property": "",
                                     "from": "",
                                     "to": "",
                                     "reg": false,
                                     "x": 590,
                                     "y": 540,
                                     "wires": [
                                         [
                                             "96648808fea1f662"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "eed8a7e060b7edf4",
                                     "type": "inject",
                                     "z": "cacb47b4dea2692d",
                                     "name": "Jarvis Nachricht",
                                     "props": [
                                         {
                                             "p": "payload"
                                         },
                                         {
                                             "p": "topic",
                                             "vt": "str"
                                         }
                                     ],
                                     "repeat": "",
                                     "crontab": "",
                                     "once": false,
                                     "onceDelay": 0.1,
                                     "topic": "Jarvis Nachricht",
                                     "payload": "\"<iFrame src=https://www.iobroker.net/de/media/iobroker-simple-overview.png height=\\\"350\\\" width=\\\"350\\\" scroll=true after height=\\\"400\\\"></iFrame>\"",
                                     "payloadType": "str",
                                     "x": 360,
                                     "y": 540,
                                     "wires": [
                                         [
                                             "0be55e6a34d1b37b"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "96648808fea1f662",
                                     "type": "debug",
                                     "z": "cacb47b4dea2692d",
                                     "name": "Jarvis Notification Objekt",
                                     "active": true,
                                     "tosidebar": true,
                                     "console": false,
                                     "tostatus": false,
                                     "complete": "payload",
                                     "targetType": "msg",
                                     "statusVal": "",
                                     "statusType": "auto",
                                     "x": 850,
                                     "y": 540,
                                     "wires": []
                                 }
                              ]
                              

                              Jeder Flow bzw. jedes Script, das ich hier poste implementiert jeder auf eigene Gefahr. Flows und Scripts können Fehler aufweisen und weder der Seitenbetreiber noch ich persönlich können hierfür haftbar gemacht werden. Das gleiche gilt für Empfehlungen aller Art.

                              R 1 Reply Last reply
                              1
                              • mickymM mickym

                                @mcu sagte in Jarvis v3 Popup möglich?:

                                @renegade-0
                                Vielleicht kann @mickym dir helfen, ich kenne mich mit node-red gar nicht aus.
                                https://mcuiobroker.gitbook.io/jarvis-infos/jarvis/besonderheiten-v3/notifications-pro/synology-bild

                                @mickym : Bitte so erklären, dass ich es in die Doku mit aufnehmen kann. Vielen Dank.

                                Nun ich hab einfach Deinen Code mit dem Link in eine function Node kopiert - man kann das nun natürlich auch ohne die function Node machen:

                                Sprich das Objekt, dass @Renegade-0 in sein Objekt kopieren will ist einfach das hier:

                                {
                                  "title": "Es hat geklingelt",
                                  "message": "<iFrame src=https://www.iobroker.net/de/media/iobroker-simple-overview.png height=\"350\" width=\"350\" scroll=true after height=\"400\"></iFrame>",
                                  "state": "unread",
                                  "criticality": "none",
                                  "display": "popup",
                                  "timeout": 180000,
                                  "snackbarOrigin": {},
                                  "icon": "bell-ring-outline",
                                  "iconColor": "#5D5DED",
                                  "backgroundColor": "black",
                                  "fontColor": "white",
                                  "focusTab": ""
                                }
                                

                                Ich hab aber einfach, dass was Du in dem Code machst verwendest und in eine function Node kopiert:

                                Das einzige was ich geändert habe ist, dass man das Auslesen des Datenpunktes mit der URL zu dem Bild im Flow nun vorgelagert ist und das Objekt nicht im Code stringifiziert wird, damit man ggf. noch was ändern kann. 😉

                                7ded7a92-e417-4c72-af23-f6d13c22cba4-image.png

                                Dein Code bleibt also nahezu unverändert in der function Node:

                                3c777926-5b91-43d3-b32e-6d5a78f010e2-image.png

                                Hier der Flow zum Import:

                                [
                                   {
                                       "id": "5ef0a4478036e523",
                                       "type": "function",
                                       "z": "cacb47b4dea2692d",
                                       "name": "Synology-Bild in der Notification",
                                       "func": "var jarvisNotify = {};\n//Beispiele\njarvisNotify.title = \"Es hat geklingelt\";\n// \"<b>Dies ist BOLD</b>\"\n// let httpAdr = getState('synology.0.SurveillanceStation.cameras.Eingang.linkMjpegHttpPath').val;\nlet httpAdr = msg.httpAdr;\n\nhttpAdr = httpAdr.replace('\"', \"%22\");\nhttpAdr = httpAdr.replace('\"', \"%22\");\njarvisNotify.message = '<iFrame src=' + String(httpAdr) + ' height=\"350\" width=\"350\" scroll=true after height=\"400\"></iFrame>';\n\njarvisNotify.state = \"unread\";          //Damit bleibt die Benachrichtigung auch nach POPUP ungelesen und wird oben angezeigt mit der Zahl\njarvisNotify.criticality = \"none\";      // error,warning,info,success\njarvisNotify.display = \"popup\";          //drawer,snackbar,popup, none für focusTab\njarvisNotify.timeout = 180000;  //5000ms -> 5 Sekunden\njarvisNotify.snackbarOrigin = {};       //\"snackbarOrigin\": { \"horizontal\": \"...\", \"vertical\": \"\" }, \n// optional, applies when display is snackbar, { horizontal: 'center' | 'left' | 'right', vertical: 'bottom' | 'top' }\njarvisNotify.icon = \"bell-ring-outline\"; //mdi Iconify\njarvisNotify.iconColor = \"#5D5DED\";\njarvisNotify.backgroundColor = \"black\";\njarvisNotify.fontColor = \"white\";\njarvisNotify.focusTab = \"\"; //focus a certain tab\n\n// setState('jarvis.0.addNotification', JSON.stringify(jarvisNotify));\nmsg.payload = jarvisNotify;\nreturn msg;",
                                       "outputs": 1,
                                       "noerr": 0,
                                       "initialize": "",
                                       "finalize": "",
                                       "libs": [],
                                       "x": 550,
                                       "y": 340,
                                       "wires": [
                                           [
                                               "5df0cada653f60d3",
                                               "c05c57a32531b7a7"
                                           ]
                                       ]
                                   },
                                   {
                                       "id": "425bdd8b537b499f",
                                       "type": "ioBroker get",
                                       "z": "cacb47b4dea2692d",
                                       "name": "httpAdr",
                                       "topic": "0_userdata.0.Test.url",
                                       "attrname": "httpAdr",
                                       "payloadType": "value",
                                       "errOnInvalidState": "nothing",
                                       "x": 320,
                                       "y": 340,
                                       "wires": [
                                           [
                                               "5ef0a4478036e523"
                                           ]
                                       ]
                                   },
                                   {
                                       "id": "0cc18f9ac32e84f6",
                                       "type": "inject",
                                       "z": "cacb47b4dea2692d",
                                       "name": "",
                                       "props": [
                                           {
                                               "p": "trigger",
                                               "v": "true",
                                               "vt": "bool"
                                           }
                                       ],
                                       "repeat": "",
                                       "crontab": "",
                                       "once": false,
                                       "onceDelay": 0.1,
                                       "topic": "",
                                       "x": 170,
                                       "y": 340,
                                       "wires": [
                                           [
                                               "425bdd8b537b499f"
                                           ]
                                       ]
                                   },
                                   {
                                       "id": "5df0cada653f60d3",
                                       "type": "debug",
                                       "z": "cacb47b4dea2692d",
                                       "name": "Jarvis Notification Objekt",
                                       "active": true,
                                       "tosidebar": true,
                                       "console": false,
                                       "tostatus": false,
                                       "complete": "payload",
                                       "targetType": "msg",
                                       "statusVal": "",
                                       "statusType": "auto",
                                       "x": 810,
                                       "y": 400,
                                       "wires": []
                                   },
                                   {
                                       "id": "2334bd2f27160450",
                                       "type": "ioBroker out",
                                       "z": "cacb47b4dea2692d",
                                       "name": "",
                                       "topic": "jarvis.0.addNotification",
                                       "ack": "false",
                                       "autoCreate": "false",
                                       "stateName": "",
                                       "role": "",
                                       "payloadType": "",
                                       "readonly": "",
                                       "stateUnit": "",
                                       "stateMin": "",
                                       "stateMax": "",
                                       "x": 1000,
                                       "y": 340,
                                       "wires": []
                                   },
                                   {
                                       "id": "c05c57a32531b7a7",
                                       "type": "json",
                                       "z": "cacb47b4dea2692d",
                                       "name": "",
                                       "property": "payload",
                                       "action": "",
                                       "pretty": false,
                                       "x": 770,
                                       "y": 340,
                                       "wires": [
                                           [
                                               "2334bd2f27160450",
                                               "aa76732d72377616"
                                           ]
                                       ]
                                   },
                                   {
                                       "id": "aa76732d72377616",
                                       "type": "debug",
                                       "z": "cacb47b4dea2692d",
                                       "name": "Stringified ;)",
                                       "active": true,
                                       "tosidebar": true,
                                       "console": false,
                                       "tostatus": false,
                                       "complete": "payload",
                                       "targetType": "msg",
                                       "statusVal": "",
                                       "statusType": "auto",
                                       "x": 970,
                                       "y": 300,
                                       "wires": []
                                   }
                                ]
                                

                                Für die Doku langt es dieses Objekt von oben vorzugeben, das Parmetrisieren müssen die Leute innerhalb von NR selbst machen:

                                9ff10e63-85ef-41e1-b01b-6a6d11c55306-image.png

                                [
                                   {
                                       "id": "0be55e6a34d1b37b",
                                       "type": "change",
                                       "z": "cacb47b4dea2692d",
                                       "name": "Jarvis Notification Objekt",
                                       "rules": [
                                           {
                                               "t": "set",
                                               "p": "payload",
                                               "pt": "msg",
                                               "to": "{\t   \"title\":\"Es hat geklingelt\",\t   \"message\":payload,\t   \"state\":\"unread\",\t   \"criticality\":\"none\",\t   \"display\":\"popup\",\t   \"timeout\":180000,\t   \"snackbarOrigin\":{},\t   \"icon\":\"bell-ring-outline\",\t   \"iconColor\":\"#5D5DED\",\t   \"backgroundColor\":\"black\",\t   \"fontColor\":\"white\",\t   \"focusTab\":\"\"\t}",
                                               "tot": "jsonata"
                                           }
                                       ],
                                       "action": "",
                                       "property": "",
                                       "from": "",
                                       "to": "",
                                       "reg": false,
                                       "x": 590,
                                       "y": 540,
                                       "wires": [
                                           [
                                               "96648808fea1f662"
                                           ]
                                       ]
                                   },
                                   {
                                       "id": "eed8a7e060b7edf4",
                                       "type": "inject",
                                       "z": "cacb47b4dea2692d",
                                       "name": "Jarvis Nachricht",
                                       "props": [
                                           {
                                               "p": "payload"
                                           },
                                           {
                                               "p": "topic",
                                               "vt": "str"
                                           }
                                       ],
                                       "repeat": "",
                                       "crontab": "",
                                       "once": false,
                                       "onceDelay": 0.1,
                                       "topic": "Jarvis Nachricht",
                                       "payload": "\"<iFrame src=https://www.iobroker.net/de/media/iobroker-simple-overview.png height=\\\"350\\\" width=\\\"350\\\" scroll=true after height=\\\"400\\\"></iFrame>\"",
                                       "payloadType": "str",
                                       "x": 360,
                                       "y": 540,
                                       "wires": [
                                           [
                                               "0be55e6a34d1b37b"
                                           ]
                                       ]
                                   },
                                   {
                                       "id": "96648808fea1f662",
                                       "type": "debug",
                                       "z": "cacb47b4dea2692d",
                                       "name": "Jarvis Notification Objekt",
                                       "active": true,
                                       "tosidebar": true,
                                       "console": false,
                                       "tostatus": false,
                                       "complete": "payload",
                                       "targetType": "msg",
                                       "statusVal": "",
                                       "statusType": "auto",
                                       "x": 850,
                                       "y": 540,
                                       "wires": []
                                   }
                                ]
                                

                                R Offline
                                R Offline
                                Renegade 0
                                wrote on last edited by Renegade 0
                                #15

                                @mickym
                                Ah OK, versteh ich das richtig, dass du quasi zuerst über JS ein Objekt erzeugst, dass dann von JSON in String konvertierst und dann ins addNotification schreibst?

                                mickymM 1 Reply Last reply
                                0
                                • R Renegade 0

                                  @mickym
                                  Ah OK, versteh ich das richtig, dass du quasi zuerst über JS ein Objekt erzeugst, dass dann von JSON in String konvertierst und dann ins addNotification schreibst?

                                  mickymM Offline
                                  mickymM Offline
                                  mickym
                                  Most Active
                                  wrote on last edited by mickym
                                  #16

                                  @renegade-0 Ja du musst immer Objekte stringifizieren, wenn du sie in einen iobroker Datenpunkt schreibst. Das Originalskript macht das ja auch. Aber ich hab dir ja das Objekt bereits extrahiert, das via JS erzeugt wird, so dass du es direkt verwenden kannst.

                                  Jeder Flow bzw. jedes Script, das ich hier poste implementiert jeder auf eigene Gefahr. Flows und Scripts können Fehler aufweisen und weder der Seitenbetreiber noch ich persönlich können hierfür haftbar gemacht werden. Das gleiche gilt für Empfehlungen aller Art.

                                  R 1 Reply Last reply
                                  0
                                  • mickymM mickym

                                    @renegade-0 Ja du musst immer Objekte stringifizieren, wenn du sie in einen iobroker Datenpunkt schreibst. Das Originalskript macht das ja auch. Aber ich hab dir ja das Objekt bereits extrahiert, das via JS erzeugt wird, so dass du es direkt verwenden kannst.

                                    R Offline
                                    R Offline
                                    Renegade 0
                                    wrote on last edited by
                                    #17

                                    @mickym
                                    Ja. das ist mir schon klar. Nur der Schritt mit dem exec war mir neu. Den finde ich durchaus interessant 🙂

                                    Kann man das "Löschen", "archivieren" und "als gelesen markieren" auch ändern?

                                    1 Reply Last reply
                                    0
                                    Reply
                                    • Reply as topic
                                    Log in to reply
                                    • Oldest to Newest
                                    • Newest to Oldest
                                    • Most Votes


                                    Support us

                                    ioBroker
                                    Community Adapters
                                    Donate

                                    48

                                    Online

                                    32.4k

                                    Users

                                    81.3k

                                    Topics

                                    1.3m

                                    Posts
                                    Community
                                    Impressum | Datenschutz-Bestimmungen | Nutzungsbedingungen
                                    ioBroker Community 2014-2025
                                    logo
                                    • Login

                                    • Don't have an account? Register

                                    • Login or register to search.
                                    • First post
                                      Last post
                                    0
                                    • Recent
                                    • Tags
                                    • Unread 0
                                    • Categories
                                    • Unreplied
                                    • Popular
                                    • GitHub
                                    • Docu
                                    • Hilfe