Skip to content
  • Home
  • 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
ioBroker Logo

Community Forum

donate donate
  1. ioBroker Community Home
  2. Deutsch
  3. Skripten / Logik
  4. Blockly
  5. [gelöst] heizoel - Preis zu festem Lieferanten suchen

NEWS

  • Neuer ioBroker-Blog online: Monatsrückblick März/April 2026
    BluefoxB
    Bluefox
    5
    1
    130

  • Verwendung von KI bitte immer deutlich kennzeichnen
    HomoranH
    Homoran
    8
    1
    166

  • Monatsrückblick Januar/Februar 2026 ist online!
    BluefoxB
    Bluefox
    18
    1
    869

[gelöst] heizoel - Preis zu festem Lieferanten suchen

Scheduled Pinned Locked Moved Blockly
7 Posts 2 Posters 469 Views 1 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.
  • O Offline
    O Offline
    oranggila
    wrote on last edited by oranggila
    #1

    In der Objektliste stehen die Händler ja nach Preis aufsteigend sortiert, d.h. heizoel.0.hoe2000.Items01-Items15.
    Ich möchte aber immer nur für einen festen Anbieter in meiner Nähe abfragen. Der stehen also mal unter Item03, mal unter Item11 etc.
    Wie parse ich dann am besten nach heizoel.0.hoe2000.Itemsxx.Name (z.B. "Huber Brennstoffe") und lasse mir heizoel.0.hoe2000.Itemsxx.NetUnitPrice zurückgeben?

    Intel NUC - ioBroker in Proxmox-VM, Zigbee TCP CC2652P2, MG4 Trophy (e-Auto)

    paul53P 1 Reply Last reply
    0
    • O oranggila

      In der Objektliste stehen die Händler ja nach Preis aufsteigend sortiert, d.h. heizoel.0.hoe2000.Items01-Items15.
      Ich möchte aber immer nur für einen festen Anbieter in meiner Nähe abfragen. Der stehen also mal unter Item03, mal unter Item11 etc.
      Wie parse ich dann am besten nach heizoel.0.hoe2000.Itemsxx.Name (z.B. "Huber Brennstoffe") und lasse mir heizoel.0.hoe2000.Itemsxx.NetUnitPrice zurückgeben?

      paul53P Offline
      paul53P Offline
      paul53
      wrote on last edited by paul53
      #2

      @oranggila sagte: "Huber Brennstoffe") und lasse mir heizoel.0.hoe2000.Itemsxx.NetUnitPrice zurückgeben?

      Blockly_temp.JPG

      JS-Funktion Name(id):

      id = id.replace('NetUnitPrice', 'Name');
      return getState(id).val;
      

      Der Preis bei "Huber Brennstoffe" muss sich erst ändern, damit er in den Datenpunkt geschrieben wird.

      Bitte verzichtet auf Chat-Nachrichten, denn die Handhabung ist grauenhaft !
      Produktiv: RPi 2 mit S.USV, HM-MOD-RPI und SLC-USB-Stick mit root fs

      O 1 Reply Last reply
      0
      • paul53P paul53

        @oranggila sagte: "Huber Brennstoffe") und lasse mir heizoel.0.hoe2000.Itemsxx.NetUnitPrice zurückgeben?

        Blockly_temp.JPG

        JS-Funktion Name(id):

        id = id.replace('NetUnitPrice', 'Name');
        return getState(id).val;
        

        Der Preis bei "Huber Brennstoffe" muss sich erst ändern, damit er in den Datenpunkt geschrieben wird.

        O Offline
        O Offline
        oranggila
        wrote on last edited by
        #3

        @paul53 Wow, so schlankes Script! Vielen Dank, ich hab es übernommen. 👍 Nun warte ich mal, ob der Datenpunkt aktualisiert wird, wenn sich der Preis wieder ändert. Ich berichte dann

        Intel NUC - ioBroker in Proxmox-VM, Zigbee TCP CC2652P2, MG4 Trophy (e-Auto)

        paul53P 1 Reply Last reply
        0
        • O oranggila

          @paul53 Wow, so schlankes Script! Vielen Dank, ich hab es übernommen. 👍 Nun warte ich mal, ob der Datenpunkt aktualisiert wird, wenn sich der Preis wieder ändert. Ich berichte dann

          paul53P Offline
          paul53P Offline
          paul53
          wrote on last edited by
          #4

          @oranggila sagte: Nun warte ich mal, ob der Datenpunkt aktualisiert wird

          Du kannst es beschleunigen, indem du den Preis bei "Huber Brennstoffe" manuell änderst (z.B. 1 Cent mehr als der aktuelle Preis).

          Bitte verzichtet auf Chat-Nachrichten, denn die Handhabung ist grauenhaft !
          Produktiv: RPi 2 mit S.USV, HM-MOD-RPI und SLC-USB-Stick mit root fs

          O 1 Reply Last reply
          0
          • paul53P paul53

            @oranggila sagte: Nun warte ich mal, ob der Datenpunkt aktualisiert wird

            Du kannst es beschleunigen, indem du den Preis bei "Huber Brennstoffe" manuell änderst (z.B. 1 Cent mehr als der aktuelle Preis).

            O Offline
            O Offline
            oranggila
            wrote on last edited by
            #5

            @paul53 Trigger löst nicht aus bei manueller Änderung. Dieses Test-Blockly müsste doch etwas ins log schreiben:
            c2fb47d8-9fe6-44a5-94a6-acb33bb89e1c-image.png

            Das Blockly sieht so aus:
            44455de6-cdcb-4fc3-ae3c-b56d3ec92818-image.png

            id = id.replace('NetUnitPrice', 'Name');
            return getState(id).val;
            

            Intel NUC - ioBroker in Proxmox-VM, Zigbee TCP CC2652P2, MG4 Trophy (e-Auto)

            paul53P 1 Reply Last reply
            0
            • O oranggila

              @paul53 Trigger löst nicht aus bei manueller Änderung. Dieses Test-Blockly müsste doch etwas ins log schreiben:
              c2fb47d8-9fe6-44a5-94a6-acb33bb89e1c-image.png

              Das Blockly sieht so aus:
              44455de6-cdcb-4fc3-ae3c-b56d3ec92818-image.png

              id = id.replace('NetUnitPrice', 'Name');
              return getState(id).val;
              
              paul53P Offline
              paul53P Offline
              paul53
              wrote on last edited by paul53
              #6

              @oranggila sagte: Dieses Test-Blockly müsste doch etwas ins log schreiben:

              Nein: "NetUnitPrice" != "NetUnitPreis"

              Bitte verzichtet auf Chat-Nachrichten, denn die Handhabung ist grauenhaft !
              Produktiv: RPi 2 mit S.USV, HM-MOD-RPI und SLC-USB-Stick mit root fs

              O 1 Reply Last reply
              0
              • paul53P paul53

                @oranggila sagte: Dieses Test-Blockly müsste doch etwas ins log schreiben:

                Nein: "NetUnitPrice" != "NetUnitPreis"

                O Offline
                O Offline
                oranggila
                wrote on last edited by
                #7

                @paul53 Oh ja😑 , muss natürlich "NetUnitPrice" heißen....und schon gehts. Datenpunkt wird aktualisiert.
                Super danke dir!

                Intel NUC - ioBroker in Proxmox-VM, Zigbee TCP CC2652P2, MG4 Trophy (e-Auto)

                1 Reply Last reply
                0

                Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                With your input, this post could be even better 💗

                Register Login
                Reply
                • Reply as topic
                Log in to reply
                • Oldest to Newest
                • Newest to Oldest
                • Most Votes


                Support us

                ioBroker
                Community Adapters
                Donate

                284

                Online

                32.8k

                Users

                82.7k

                Topics

                1.3m

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

                • Don't have an account? Register

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