[ { "id": "21187061eeed1857", "type": "tab", "label": "dashboard", "disabled": false, "info": "", "env": [] }, { "id": "806bc36caad66e27", "type": "inject", "z": "21187061eeed1857", "name": "false", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "", "payload": "false", "payloadType": "bool", "x": 150, "y": 140, "wires": [ [ "bbfdc8137a962d9d", "d81fd4a611330eff" ] ] }, { "id": "bbfdc8137a962d9d", "type": "ui_gauge", "z": "21187061eeed1857", "name": "温度", "group": "20f15b463fd5f1d6", "order": 0, "width": 0, "height": 0, "gtype": "gage", "title": "温度", "label": "℃", "format": "{{value}}", "min": 0, "max": "1", "colors": [ "#00b500", "#e6e600", "#ca3838" ], "seg1": "", "seg2": "", "diff": false, "className": "", "x": 430, "y": 120, "wires": [] }, { "id": "03607acbb92d871c", "type": "inject", "z": "21187061eeed1857", "name": "true", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "", "payload": "true", "payloadType": "bool", "x": 150, "y": 80, "wires": [ [ "bbfdc8137a962d9d", "d81fd4a611330eff" ] ] }, { "id": "d81fd4a611330eff", "type": "ui_switch", "z": "21187061eeed1857", "name": "开关", "label": "switch", "tooltip": "", "group": "20f15b463fd5f1d6", "order": 1, "width": 0, "height": 0, "passthru": true, "decouple": "false", "topic": "topic", "topicType": "msg", "style": "", "onvalue": "true", "onvalueType": "bool", "onicon": "", "oncolor": "", "offvalue": "false", "offvalueType": "bool", "officon": "", "offcolor": "", "animate": false, "className": "", "x": 430, "y": 40, "wires": [ [ "2ba2ac50f8e55b5e" ] ] }, { "id": "2ba2ac50f8e55b5e", "type": "debug", "z": "21187061eeed1857", "name": "debug 10", "active": true, "tosidebar": true, "console": false, "tostatus": false, "complete": "false", "statusVal": "", "statusType": "auto", "x": 580, "y": 40, "wires": [] }, { "id": "9f0c31c38c14555e", "type": "ui_button", "z": "21187061eeed1857", "name": "", "group": "20f15b463fd5f1d6", "order": 2, "width": 0, "height": 0, "passthru": false, "label": "{{background}}", "tooltip": "", "color": "", "bgcolor": "{{background}}", "className": "", "icon": "", "payload": "", "payloadType": "str", "topic": "topic", "topicType": "msg", "x": 450, "y": 240, "wires": [ [ "8778c7a002f80c83" ] ] }, { "id": "9f647c6a2deff125", "type": "inject", "z": "21187061eeed1857", "name": "green", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" }, { "p": "background", "v": "green", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "", "payload": "", "payloadType": "date", "x": 110, "y": 240, "wires": [ [ "bd6127ae7bd836ab" ] ] }, { "id": "1ae721183f7867fc", "type": "inject", "z": "21187061eeed1857", "name": "gray", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "", "payload": "", "payloadType": "date", "x": 110, "y": 300, "wires": [ [ "6d45a45ab80c495a" ] ] }, { "id": "8778c7a002f80c83", "type": "debug", "z": "21187061eeed1857", "name": "debug 11", "active": true, "tosidebar": true, "console": false, "tostatus": false, "complete": "false", "statusVal": "", "statusType": "auto", "x": 600, "y": 240, "wires": [] }, { "id": "7c3bcd2cfc8f0565", "type": "debug", "z": "21187061eeed1857", "name": "debug 12", "active": true, "tosidebar": true, "console": false, "tostatus": false, "complete": "true", "targetType": "full", "statusVal": "", "statusType": "auto", "x": 460, "y": 300, "wires": [] }, { "id": "bd6127ae7bd836ab", "type": "function", "z": "21187061eeed1857", "name": "green", "func": "msg.background = \"green\"\nreturn msg;", "outputs": 1, "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 250, "y": 240, "wires": [ [ "9f0c31c38c14555e", "7c3bcd2cfc8f0565" ] ] }, { "id": "6d45a45ab80c495a", "type": "function", "z": "21187061eeed1857", "name": "gray", "func": "msg.background = \"gray\"\nreturn msg;", "outputs": 1, "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 250, "y": 300, "wires": [ [ "9f0c31c38c14555e", "7c3bcd2cfc8f0565" ] ] }, { "id": "746325349ecbaf52", "type": "inject", "z": "21187061eeed1857", "name": "red", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" }, { "p": "background", "v": "red", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "", "payload": "", "payloadType": "date", "x": 110, "y": 360, "wires": [ [ "9f0c31c38c14555e" ] ] }, { "id": "755c8feef80849c7", "type": "comment", "z": "21187061eeed1857", "name": "按钮根据msg.background变色", "info": "", "x": 180, "y": 200, "wires": [] }, { "id": "20f15b463fd5f1d6", "type": "ui_group", "name": "Group 0", "tab": "2f0637c94b1d31ce", "order": 1, "disp": true, "width": "6", "collapse": false, "className": "" }, { "id": "2f0637c94b1d31ce", "type": "ui_tab", "name": "Home", "icon": "dashboard", "disabled": false, "hidden": false } ]