Hi,
I'm trying to use ui_node to switch tabs.
From "tab B" to "tab A" goes well, while from "tab A" does not work as expected.
When I want to switch from "tab A" to "tab B", I have to click on the created button(double) to make switch tab.
Below is an simulation flow.
Please, can anyone look at what it's all about, I'm wrong somewhere, or does this not work as expected?
[{"id":"3f007fb5.0a17f","type":"tab","label":"Flow 3","disabled":false,"info":""},{"id":"fe2de2d8.bb22c","type":"change","z":"3f007fb5.0a17f","name":"arming","rules":[{"t":"set","p":"payload","pt":"msg","to":"Alarm Arming in 5 Seconds","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":170,"y":240,"wires":[["652c802b.90614","38d6322f.70265e"]]},{"id":"74bc26a8.a31fb8","type":"ui_text","z":"3f007fb5.0a17f","group":"e3dfdad2.15b088","order":14,"width":"4","height":"1","name":"Alarm Status is:","label":"Alarm Status is:","format":"","layout":"row-spread","x":1020,"y":340,"wires":[]},{"id":"2ab71d1e.218e52","type":"change","z":"3f007fb5.0a17f","name":"disarming","rules":[{"t":"set","p":"payload","pt":"msg","to":"Alarm Disarming","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":160,"y":420,"wires":[["67dce5c.a3f2a1c","d1e6997.356de68"]]},{"id":"a3e9d930.74f708","type":"change","z":"3f007fb5.0a17f","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"DISARMED","tot":"str"},{"t":"set","p":"color","pt":"msg","to":"green","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":600,"y":380,"wires":[["891c099c.c29aa8"]]},{"id":"758d43fa.31f95c","type":"function","z":"3f007fb5.0a17f","name":"countdown_text","func":"msg.txt={\"payload\":\"ARMED\",\"color\":\"red\"}\nmsg.color={\"color\":\"red\"}\nfor (var i=5; i>0; i--) {\n node.send({payload:\".. \"+i+\" ..\"})\n }\n//return null;\nreturn msg.txt;\n","outputs":1,"noerr":0,"x":600,"y":260,"wires":[["5d835318.71c28c"]]},{"id":"5d835318.71c28c","type":"delay","z":"3f007fb5.0a17f","name":"","pauseType":"rate","timeout":"2","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":790,"y":260,"wires":[["762bb0bc.d53cd","891c099c.c29aa8"]]},{"id":"762bb0bc.d53cd","type":"debug","z":"3f007fb5.0a17f","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","x":1010,"y":260,"wires":[]},{"id":"67dce5c.a3f2a1c","type":"delay","z":"3f007fb5.0a17f","name":"Delay 0.5 Seconds","pauseType":"delay","timeout":"500","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":370,"y":380,"wires":[["a3e9d930.74f708"]]},{"id":"652c802b.90614","type":"delay","z":"3f007fb5.0a17f","name":"Delay 0.25 Seconds","pauseType":"delay","timeout":"250","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":380,"y":260,"wires":[["758d43fa.31f95c"]]},{"id":"891c099c.c29aa8","type":"ui_template","z":"3f007fb5.0a17f","group":"e3dfdad2.15b088","name":"","order":16,"width":"2","height":"1","format":"<style>\n.center {\n margin: auto;\n color:yellow;\n }\n</style>\n\n<div class=\"center\">\n <p style=\"color:{{msg.color}}\"><b>{{msg.payload}}</b></p>\n</div>\n","storeOutMessages":true,"fwdInMessages":true,"templateScope":"local","x":1000,"y":380,"wires":[[]]},{"id":"b76a7f99.d3e58","type":"ui_ui_control","z":"3f007fb5.0a17f","name":"go to screen","x":790,"y":440,"wires":[[]]},{"id":"1c262b11.3fffd5","type":"ui_ui_control","z":"3f007fb5.0a17f","name":"go to screen","x":790,"y":200,"wires":[[]]},{"id":"46cadbac.366154","type":"ui_button","z":"3f007fb5.0a17f","name":"","group":"723b1156.d0dde","order":2,"width":0,"height":0,"passthru":false,"label":"switch to Tab A","tooltip":"","color":"","bgcolor":"","icon":"","payload":"","payloadType":"str","topic":"","x":100,"y":280,"wires":[["fe2de2d8.bb22c"]]},{"id":"ce34ab74.ab3ca8","type":"inject","z":"3f007fb5.0a17f","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":100,"y":200,"wires":[["fe2de2d8.bb22c"]]},{"id":"1f10ad8b.f28722","type":"inject","z":"3f007fb5.0a17f","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":100,"y":380,"wires":[["2ab71d1e.218e52"]]},{"id":"906c887a.dec738","type":"debug","z":"3f007fb5.0a17f","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":770,"y":480,"wires":[]},{"id":"28275f91.91f01","type":"debug","z":"3f007fb5.0a17f","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":770,"y":160,"wires":[]},{"id":"4c856646.51bf58","type":"ui_button","z":"3f007fb5.0a17f","name":"","group":"4fca4d4a.2e6784","order":2,"width":0,"height":0,"passthru":false,"label":"switch to Tab B","tooltip":"","color":"","bgcolor":"","icon":"","payload":"","payloadType":"str","topic":"","x":120,"y":460,"wires":[["2ab71d1e.218e52"]]},{"id":"38d6322f.70265e","type":"trigger","z":"3f007fb5.0a17f","op1":"","op2":"{\"tab\":\"Tab A\"}","op1type":"nul","op2type":"json","duration":"1","extend":false,"units":"s","reset":"","bytopic":"all","name":"","x":340,"y":200,"wires":[["1c262b11.3fffd5"]]},{"id":"d1e6997.356de68","type":"trigger","z":"3f007fb5.0a17f","op1":"","op2":"{\"tab\":\"Tab B\"}","op1type":"nul","op2type":"json","duration":"1","extend":false,"units":"s","reset":"","bytopic":"all","name":"","x":340,"y":440,"wires":[["b76a7f99.d3e58"]]},{"id":"e3dfdad2.15b088","type":"ui_group","name":"Group 2","tab":"22274233.5a7a2e","order":2,"disp":true,"width":6},{"id":"723b1156.d0dde","type":"ui_group","z":"","name":"Default","tab":"8758d4d8.fb5b28","disp":true,"width":"6","collapse":false},{"id":"4fca4d4a.2e6784","type":"ui_group","z":"","name":"Default","tab":"22274233.5a7a2e","order":1,"disp":true,"width":"6","collapse":false},{"id":"22274233.5a7a2e","type":"ui_tab","z":"","name":"Tab A","icon":"dashboard","order":4,"disabled":false,"hidden":false},{"id":"8758d4d8.fb5b28","type":"ui_tab","z":"","name":"Tab B","icon":"dashboard","order":5,"disabled":false,"hidden":false}]
Thx.