/
gabelchik
/
nodered
Обзор
Документация
Войти
/
gabelchik
/
nodered
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
export/WebSocket-stream/flows.json
238 строк
6 KB
Leonid Kalintsev
/export
07 июл 2026, 17:10
07 июл 2026, 17:10
7ec0f3f
Код
Авторство
О чём код?
[ { "id": "8c015fa6d2ad3f3b", "type": "tab", "label": "Поток 2", "disabled": false, "info": "", "env": [] }, { "id": "7ecf84456f4188ee", "type": "websocket out", "z": "8c015fa6d2ad3f3b", "name": "WebSocketOUT", "server": "0ff06d8f76816ca2", "client": "", "x": 1300, "y": 260, "wires": [] }, { "id": "0c1d2e9cd1e07c03", "type": "function", "z": "8c015fa6d2ad3f3b", "name": "function 1", "func": "const { optic, alloy, nut } = msg.payload;\n\nconst opticData = JSON.parse(optic);\nconst alloyData = JSON.parse(alloy);\nconst nutData = JSON.parse(nut);\n\nmsg.payload = {\n timestamp: Date.now(),\n formatted: new Date().toISOString(),\n data: {\n Alloy: alloyData,\n Nut: nutData,\n Optic: opticData\n }\n};\n\nreturn msg;", "outputs": 1, "timeout": 0, "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1100, "y": 260, "wires": [ [ "7ecf84456f4188ee" ] ] }, { "id": "d88059848b7b64e1", "type": "inject", "z": "8c015fa6d2ad3f3b", "name": "", "props": [], "repeat": "10", "crontab": "", "once": true, "onceDelay": "", "topic": "", "x": 110, "y": 260, "wires": [ [ "258e517fe34d9be2", "efb740a11e9704b2", "2b0666a08403299f" ] ] }, { "id": "258e517fe34d9be2", "type": "file in", "z": "8c015fa6d2ad3f3b", "name": "Чтение гайки", "filename": "/data/files/гайка_09-08-2026.txt", "filenameType": "str", "format": "utf8", "chunk": false, "sendError": false, "encoding": "none", "allProps": false, "x": 340, "y": 180, "wires": [ [ "3d1d1ac24d667e79" ] ] }, { "id": "efb740a11e9704b2", "type": "file in", "z": "8c015fa6d2ad3f3b", "name": "Чтение оптики", "filename": "/data/files/оптика_25-05-2025.txt", "filenameType": "str", "format": "utf8", "chunk": false, "sendError": false, "encoding": "none", "allProps": false, "x": 340, "y": 260, "wires": [ [ "16c0ccc2421c9ef6" ] ] }, { "id": "2b0666a08403299f", "type": "file in", "z": "8c015fa6d2ad3f3b", "name": "Чтение сплавов", "filename": "/data/files/сплавы_01-01-2026.txt", "filenameType": "str", "format": "utf8", "chunk": false, "sendError": false, "encoding": "none", "allProps": false, "x": 350, "y": 340, "wires": [ [ "be6ee1ef74ba6850" ] ] }, { "id": "cb8731aabbb44c20", "type": "join", "z": "8c015fa6d2ad3f3b", "name": "Объединение данных", "mode": "custom", "build": "object", "property": "payload", "propertyType": "msg", "key": "topic", "joiner": "\\n", "joinerType": "str", "useparts": false, "accumulate": false, "timeout": "", "count": "3", "reduceRight": false, "reduceExp": "", "reduceInit": "", "reduceInitType": "", "reduceFixup": "", "x": 870, "y": 260, "wires": [ [ "0c1d2e9cd1e07c03" ] ] }, { "id": "3d1d1ac24d667e79", "type": "change", "z": "8c015fa6d2ad3f3b", "name": "", "rules": [ { "t": "set", "p": "topic", "pt": "msg", "to": "nut", "tot": "str" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 580, "y": 180, "wires": [ [ "cb8731aabbb44c20" ] ] }, { "id": "16c0ccc2421c9ef6", "type": "change", "z": "8c015fa6d2ad3f3b", "name": "", "rules": [ { "t": "set", "p": "topic", "pt": "msg", "to": "optic", "tot": "str" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 580, "y": 260, "wires": [ [ "cb8731aabbb44c20" ] ] }, { "id": "be6ee1ef74ba6850", "type": "change", "z": "8c015fa6d2ad3f3b", "name": "", "rules": [ { "t": "set", "p": "topic", "pt": "msg", "to": "alloy", "tot": "str" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 580, "y": 340, "wires": [ [ "cb8731aabbb44c20" ] ] }, { "id": "0ff06d8f76816ca2", "type": "websocket-listener", "path": "/ws/timestamp", "wholemsg": "false" } ]