Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FD Custom - widget array #3

Open
JustMe0815 opened this issue Jun 14, 2023 · 2 comments
Open

FD Custom - widget array #3

JustMe0815 opened this issue Jun 14, 2023 · 2 comments

Comments

@JustMe0815
Copy link

I am having issues with creating FD custom as a widget array.
If its not a array it shows 1 widget with text just fine.
When i select Widget array and sent multiple messages with different msg.topic, it created multiple widgets, but they are all empty.

How can i get this to work?

Thanks,
Dennis

@tve
Copy link
Member

tve commented Jun 14, 2023

I assume you're using node-red? Can you post portions of your flow?

@JustMe0815
Copy link
Author

yes - node-red.

node-red-fd-corewidgets
node-red-flexdash

[ { "id": "5f12f1fbcaa42e0d", "type": "tab", "label": "FlexDash_Test", "disabled": false, "info": "", "env": [] }, { "id": "6287ed3cbd12cdd7", "type": "inject", "z": "5f12f1fbcaa42e0d", "name": "Test 1", "props": [ { "p": "payload" }, { "p": "name", "v": "Test 1", "vt": "str" }, { "p": "ip", "v": "0.0.0.1", "vt": "str" }, { "p": "ping", "v": "1", "vt": "num" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "Test 1", "payload": "", "payloadType": "date", "x": 535, "y": 195, "wires": [ [ "f4516eed836eb451" ] ] }, { "id": "f4516eed836eb451", "type": "flexdash custom", "z": "5f12f1fbcaa42e0d", "name": "Single Widget FlexDash_Test", "sfc_source": "<template>\n <div>\n <div class=\"name\">{{ name }}</div>\n <div class=\"ip\">{{ ip }}</div>\n <span class=\"ping\">{{ ping }}</span>\n </div>\n</template>\n\n<style scoped>\n .ping {\n color: red;\n }\n\n .name {\n font-weight: bold;\n }\n\n .ip {\n margin-top: 5px;\n }\n</style>\n\n<script>\n export default {\n props: {\n name: { default: \"N/A\" },\n ip: { default: \"N/A\" },\n ping: { default: \"N/A\" }\n }\n}\n</script>", "fd_container": "51307a13459c6bd2", "fd_cols": 1, "fd_rows": 1, "fd_array": false, "fd_array_max": 10, "x": 795, "y": 265, "wires": [ [] ] }, { "id": "97192cd371398c70", "type": "inject", "z": "5f12f1fbcaa42e0d", "name": "Test 2", "props": [ { "p": "payload" }, { "p": "name", "v": "Test 2", "vt": "str" }, { "p": "ip", "v": "0.0.0.2", "vt": "str" }, { "p": "ping", "v": "2", "vt": "num" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "Test 2", "payload": "", "payloadType": "date", "x": 535, "y": 230, "wires": [ [ "f4516eed836eb451" ] ] }, { "id": "b96aacdc73ba68a2", "type": "inject", "z": "5f12f1fbcaa42e0d", "name": "Test 3", "props": [ { "p": "payload" }, { "p": "name", "v": "Test 3", "vt": "str" }, { "p": "ip", "v": "0.0.0.3", "vt": "str" }, { "p": "ping", "v": "3", "vt": "num" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "Test 3", "payload": "", "payloadType": "date", "x": 535, "y": 265, "wires": [ [ "f4516eed836eb451" ] ] }, { "id": "290fb4f78e411983", "type": "inject", "z": "5f12f1fbcaa42e0d", "name": "Test 4", "props": [ { "p": "payload" }, { "p": "name", "v": "Test 4", "vt": "str" }, { "p": "ip", "v": "0.0.0.4", "vt": "str" }, { "p": "ping", "v": "4", "vt": "num" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "Test 4", "payload": "", "payloadType": "date", "x": 535, "y": 300, "wires": [ [ "f4516eed836eb451" ] ] }, { "id": "ac7bef15996cb176", "type": "inject", "z": "5f12f1fbcaa42e0d", "name": "Test 5", "props": [ { "p": "payload" }, { "p": "name", "v": "Test 5", "vt": "str" }, { "p": "ip", "v": "0.0.0.5", "vt": "str" }, { "p": "ping", "v": "5", "vt": "num" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "Test 5", "payload": "", "payloadType": "date", "x": 535, "y": 335, "wires": [ [ "f4516eed836eb451" ] ] }, { "id": "57d91fa1cbc4981c", "type": "inject", "z": "5f12f1fbcaa42e0d", "name": "Test 1", "props": [ { "p": "payload" }, { "p": "name", "v": "Test 1", "vt": "str" }, { "p": "ip", "v": "0.0.0.1", "vt": "str" }, { "p": "ping", "v": "1", "vt": "num" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "Test 1", "payload": "", "payloadType": "date", "x": 535, "y": 390, "wires": [ [ "068716b5ea213ed2" ] ] }, { "id": "068716b5ea213ed2", "type": "flexdash custom", "z": "5f12f1fbcaa42e0d", "name": "Widget Array FlexDash_Test", "sfc_source": "<template>\n <div>\n <div class=\"name\">{{ name }}</div>\n <div class=\"ip\">{{ ip }}</div>\n <span class=\"ping\">{{ ping }}</span>\n </div>\n</template>\n\n<style scoped>\n .ping {\n color: red;\n }\n\n .name {\n font-weight: bold;\n }\n\n .ip {\n margin-top: 5px;\n }\n</style>\n\n<script>\n export default {\n props: {\n name: { default: \"N/A\" },\n ip: { default: \"N/A\" },\n ping: { default: \"N/A\" }\n }\n}\n</script>", "fd_container": "51307a13459c6bd2", "fd_cols": 1, "fd_rows": 1, "fd_array": true, "fd_array_max": 10, "x": 805, "y": 460, "wires": [ [] ] }, { "id": "993dc505c0d39235", "type": "inject", "z": "5f12f1fbcaa42e0d", "name": "Test 2", "props": [ { "p": "payload" }, { "p": "name", "v": "Test 2", "vt": "str" }, { "p": "ip", "v": "0.0.0.2", "vt": "str" }, { "p": "ping", "v": "2", "vt": "num" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "Test 2", "payload": "", "payloadType": "date", "x": 535, "y": 425, "wires": [ [ "068716b5ea213ed2" ] ] }, { "id": "c5f5b1254b5e8d65", "type": "inject", "z": "5f12f1fbcaa42e0d", "name": "Test 3", "props": [ { "p": "payload" }, { "p": "name", "v": "Test 3", "vt": "str" }, { "p": "ip", "v": "0.0.0.3", "vt": "str" }, { "p": "ping", "v": "3", "vt": "num" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "Test 3", "payload": "", "payloadType": "date", "x": 535, "y": 460, "wires": [ [ "068716b5ea213ed2" ] ] }, { "id": "b042de3993eb3a62", "type": "inject", "z": "5f12f1fbcaa42e0d", "name": "Test 4", "props": [ { "p": "payload" }, { "p": "name", "v": "Test 4", "vt": "str" }, { "p": "ip", "v": "0.0.0.4", "vt": "str" }, { "p": "ping", "v": "4", "vt": "num" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "Test 4", "payload": "", "payloadType": "date", "x": 535, "y": 495, "wires": [ [ "068716b5ea213ed2" ] ] }, { "id": "603d2cbcf5435263", "type": "inject", "z": "5f12f1fbcaa42e0d", "name": "Test 5", "props": [ { "p": "payload" }, { "p": "name", "v": "Test 5", "vt": "str" }, { "p": "ip", "v": "0.0.0.5", "vt": "str" }, { "p": "ping", "v": "5", "vt": "num" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "Test 5", "payload": "", "payloadType": "date", "x": 535, "y": 530, "wires": [ [ "068716b5ea213ed2" ] ] }, { "id": "51307a13459c6bd2", "type": "flexdash container", "name": "PLC Online Status", "title": "PLC Online Status", "kind": "StdGrid", "fd_children": ",f4516eed836eb451,068716b5ea213ed2", "tab": "03fcaa8a3ab35b1b", "min_cols": 1, "max_cols": 10, "unicast": "ignore", "parent": "", "solid": false, "cols": 1, "rows": 1 }, { "id": "03fcaa8a3ab35b1b", "type": "flexdash tab", "name": "PLC Chek", "icon": "mdi-router-network", "title": "PLC Chek", "fd_children": ",51307a13459c6bd2", "fd": "e8f5aea52ab49500" } ]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants