Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Skripten / Logik
    4. Blockly
    5. Mehrere Datensätze in einer JSON-Datei in Blockly ändern

    NEWS

    • Neuer Blog: Fotos und Eindrücke aus Solingen

    • ioBroker@Smart Living Forum Solingen, 14.06. - Agenda added

    • ioBroker goes Matter ... Matter Adapter in Stable

    Mehrere Datensätze in einer JSON-Datei in Blockly ändern

    This topic has been deleted. Only users with topic management privileges can see it.
    • H
      HackyPaddy last edited by

      Hallo Leute,

      ich stehe vor der Aufgabe, dass ich in einer JSON-Datei ein bestimmtes Objekt ändern muss.

      Der Aufbau der JSON-Datei ist wie folgt:

      [
        {
          "type": "IL",
          "date": 1727805600,
          "maschine_id": "72jen",
          "temp": {
            "max": 81.24,
            "min": 72.16
          },
          "pressure": {
            "min": 62,
            "max": 96
          },
      usw...
      ]
      

      Die Datei beinhaltet ca. 500 dieser Datensätze und bei jedem Datensatz muss das Attribut "Date" vom Unix-Timestamp in ein leserliches Format gebracht werden.

      Ich brauche da mal einen Ansatz, wie ich beginne. Hat das von euch schon jemand gemacht?

      Viele Grüße

      paul53 1 Reply Last reply Reply Quote 0
      • paul53
        paul53 @HackyPaddy last edited by paul53

        @hackypaddy sagte: in ein leserliches Format gebracht werden.

        Was ist für dich ein leserliches Format?
        Etwa so (nicht getestet)?

        Blockly_temp.JPG

        H 2 Replies Last reply Reply Quote 0
        • H
          HackyPaddy @paul53 last edited by

          @paul53

          Hey Paul,

          ja, dass wäre perfekt.
          Leserlich = Vom Menschen ohne Umrechnung lesbar 🙂

          Ich probiere Deine Lösung nachher mal aus. Klingt vielversprechend.

          1 Reply Last reply Reply Quote 0
          • H
            HackyPaddy @paul53 last edited by

            @paul53

            Hat geklappt, wunderbar.

            Vielen Dank!

            1 Reply Last reply Reply Quote 0
            • First post
              Last post

            Support us

            ioBroker
            Community Adapters
            Donate

            827
            Online

            31.9k
            Users

            80.1k
            Topics

            1.3m
            Posts

            2
            4
            192
            Loading More Posts
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes
            Reply
            • Reply as topic
            Log in to reply
            Community
            Impressum | Datenschutz-Bestimmungen | Nutzungsbedingungen
            The ioBroker Community 2014-2023
            logo