martip / node-red-contrib-echarts

2 stars 1 forks source link

Suggestion - Adding example Flows as JSON #1

Open NicoloToscani opened 2 years ago

NicoloToscani commented 2 years ago

Can you provide an flow example that uses this node ?

zhangmx commented 1 year ago
[
    {
        "id": "0fcc6f74e740a064",
        "type": "echarts",
        "z": "ecb7ed79ba721ac5",
        "name": "",
        "width": "800",
        "height": "600",
        "x": 540,
        "y": 220,
        "wires": [
            [
                "2f9073a69cd71789"
            ]
        ]
    },
    {
        "id": "7d564f74eb24baa3",
        "type": "inject",
        "z": "ecb7ed79ba721ac5",
        "name": "",
        "props": [
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": true,
        "onceDelay": 0.1,
        "topic": "",
        "x": 150,
        "y": 220,
        "wires": [
            [
                "f879965489f66e18"
            ]
        ]
    },
    {
        "id": "f879965489f66e18",
        "type": "function",
        "z": "ecb7ed79ba721ac5",
        "name": "echart options",
        "func": "msg.payload = {\n    title: {\n        text: 'ECharts Getting Started Example'\n    },\n    tooltip: {},\n    legend: {\n        data: ['sales']\n    },\n    xAxis: {\n        data: ['Shirts', 'Cardigans', 'Chiffons', 'Pants', 'Heels', 'Socks']\n    },\n    yAxis: {},\n    series: [\n        {\n            name: 'sales',\n            type: 'bar',\n            data: [5, 20, 36, 10, 10, 20]\n        }\n    ]\n};\nreturn msg;",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 340,
        "y": 220,
        "wires": [
            [
                "0fcc6f74e740a064"
            ]
        ]
    },
    {
        "id": "2f9073a69cd71789",
        "type": "ui_template",
        "z": "ecb7ed79ba721ac5",
        "group": "3aeed3b66cedadf0",
        "name": "",
        "order": 0,
        "width": "21",
        "height": "12",
        "format": "<div ng-bind-html=\"msg.payload | trusted\"></div>",
        "storeOutMessages": true,
        "fwdInMessages": true,
        "resendOnRefresh": true,
        "templateScope": "local",
        "className": "",
        "x": 740,
        "y": 220,
        "wires": [
            []
        ]
    },
    {
        "id": "3aeed3b66cedadf0",
        "type": "ui_group",
        "name": "Default",
        "tab": "114af05102a61db8",
        "order": 2,
        "disp": true,
        "width": "21",
        "collapse": false,
        "className": ""
    },
    {
        "id": "114af05102a61db8",
        "type": "ui_tab",
        "name": "Home",
        "icon": "dashboard",
        "disabled": false,
        "hidden": false
    }
]