Hello All,
I am having issues converting a message payload ex ample value from debug "15" to '15'. I need the payload to be in the format 'x' so that my function node will work.
[{"id":"4d9bb02d.3c221","type":"tab","label":"Flow 3","disabled":false,"info":""},{"id":"f0379573.07efb8","type":"inject","z":"4d9bb02d.3c221","name":"","topic":"","payload":"\"ip\":10.10.10.10\"","payloadType":"str","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":2000,"y":280,"wires":[["c1ad69cb.940f48","789e8b45.05cc24"]]},{"id":"c1ad69cb.940f48","type":"change","z":"4d9bb02d.3c221","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"ip","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":2210,"y":280,"wires":[["e4a308f7.2638f8","409633ae.7428ac"]]},{"id":"e4a308f7.2638f8","type":"change","z":"4d9bb02d.3c221","name":"","rules":[{"t":"move","p":"ip","pt":"msg","to":"payload","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":2410,"y":280,"wires":[["5b20cab0.d9d224","b3a10295.f21af"]]},{"id":"5b20cab0.d9d224","type":"split","z":"4d9bb02d.3c221","name":"","splt":":","spltType":"str","arraySplt":1,"arraySpltType":"len","stream":false,"addname":"","x":2570,"y":280,"wires":[["6671f7b4.7e6248","30294987.0bd8c6"]]},{"id":"6671f7b4.7e6248","type":"switch","z":"4d9bb02d.3c221","name":"","property":"payload","propertyType":"msg","rules":[{"t":"cont","v":"10.10","vt":"str"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":2710,"y":280,"wires":[["6a44a2ae.c0bd8c","7c690a00.459d38"],[]]},{"id":"6a44a2ae.c0bd8c","type":"json","z":"4d9bb02d.3c221","name":"","property":"payload","action":"str","pretty":false,"x":2850,"y":280,"wires":[["89572b0b.3b98f8","db28a337.e513e"]]},{"id":"89572b0b.3b98f8","type":"function","z":"4d9bb02d.3c221","name":"","func":"var m =msg.payload[0].value;\nreturn msg;","outputs":1,"noerr":0,"x":2990,"y":280,"wires":[["3939e7b5.1b0588","396d35be.8f75fa"]]},{"id":"3939e7b5.1b0588","type":"change","z":"4d9bb02d.3c221","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"ip","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3170,"y":280,"wires":[["3fc9d158.1a921e"]]},{"id":"3fc9d158.1a921e","type":"debug","z":"4d9bb02d.3c221","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":3320,"y":220,"wires":[]},{"id":"789e8b45.05cc24","type":"debug","z":"4d9bb02d.3c221","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":2210,"y":200,"wires":[]},{"id":"409633ae.7428ac","type":"debug","z":"4d9bb02d.3c221","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":2370,"y":220,"wires":[]},{"id":"b3a10295.f21af","type":"debug","z":"4d9bb02d.3c221","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":2530,"y":220,"wires":[]},{"id":"30294987.0bd8c6","type":"debug","z":"4d9bb02d.3c221","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":2670,"y":220,"wires":[]},{"id":"7c690a00.459d38","type":"debug","z":"4d9bb02d.3c221","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":2830,"y":220,"wires":[]},{"id":"db28a337.e513e","type":"debug","z":"4d9bb02d.3c221","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":2990,"y":220,"wires":[]},{"id":"396d35be.8f75fa","type":"debug","z":"4d9bb02d.3c221","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":3137,"y":224,"wires":[]}]