I am new in Node red following code i have created following example with 3 gauges in it.
I wants to show limit of all gauges dynamically by single function not individual function for each
[{"id":"ca33fa4c.a42348","type":"mqtt in","z":"b0c1d592.40c9b8","name":"loadprofileout","topic":"LOAD PROFILE","qos":"2","datatype":"auto","broker":"f52c9088.7d7c1","x":110,"y":340,"wires":[["61549806.8da518"]]},{"id":"86c9ba30.a128a8","type":"mqtt out","z":"b0c1d592.40c9b8","name":"loadprofile","topic":"LOAD PROFILE","qos":"0","retain":"","broker":"f52c9088.7d7c1","x":129,"y":260,"wires":[]},{"id":"61549806.8da518","type":"json","z":"b0c1d592.40c9b8","name":"","property":"payload","action":"","pretty":false,"x":250,"y":340,"wires":[["81fee1bc.eaa1e"]]},{"id":"7c9fcf1d.f0cae","type":"split","z":"b0c1d592.40c9b8","name":"","splt":":","spltType":"str","arraySplt":"3","arraySpltType":"len","stream":false,"addname":"","x":250,"y":400,"wires":[["4e001d06.b60404"]]},{"id":"4e001d06.b60404","type":"function","z":"b0c1d592.40c9b8","name":"","func":"var parts = msg.payload.split('\":\"');\nmsg.key = parts[0].replace('\"', \"\");\nmsg.val = parts[1]\nmsg.ui_control = {max:parseInt(msg.payload)-100};\n/*var x = parseInt(msg.val)+100;\nvar y = parseInt(msg.val)-100;\nmsg = {ui_control:{max:x,min:y}};\n*/\n\nreturn msg;\n","outputs":1,"noerr":0,"x":270,"y":460,"wires":[["a836199b.351868"]]},{"id":"a836199b.351868","type":"join","z":"b0c1d592.40c9b8","name":"","mode":"custom","build":"array","property":"","propertyType":"full","key":"topic","joiner":"\\n","joinerType":"str","accumulate":false,"timeout":"","count":"","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"","reduceFixup":"","x":430,"y":400,"wires":[["8dfa8b92.b80a58","f417118a.a172b","c0f916de.079f68","c6adacbd.bd3ae","3eaaa0c.783c36"]]},{"id":"81fee1bc.eaa1e","type":"split","z":"b0c1d592.40c9b8","name":"","splt":":","spltType":"str","arraySplt":"3","arraySpltType":"len","stream":false,"addname":"","x":370,"y":340,"wires":[["7c9fcf1d.f0cae"]]},{"id":"c0f916de.079f68","type":"debug","z":"b0c1d592.40c9b8","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":510,"y":480,"wires":[]},{"id":"3eaaa0c.783c36","type":"ui_gauge","z":"b0c1d592.40c9b8","name":"","group":"98ad6404.0f5d38","order":4,"width":"4","height":"4","gtype":"gage","title":"{{payload[3].parts.key}}","label":"units","format":"{{payload[3].key}}","min":0,"max":"3000","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":770,"y":440,"wires":[]},{"id":"c6adacbd.bd3ae","type":"ui_gauge","z":"b0c1d592.40c9b8","name":"","group":"98ad6404.0f5d38","order":3,"width":"4","height":"4","gtype":"gage","title":"{{payload[2].parts.key}}","label":"units","format":"{{payload[2].key}}","min":0,"max":"2000","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":770,"y":380,"wires":[]},{"id":"f417118a.a172b","type":"ui_gauge","z":"b0c1d592.40c9b8","name":"","group":"98ad6404.0f5d38","order":2,"width":"4","height":"4","gtype":"gage","title":"{{msg.payload[1].parts.key}}","label":"units","format":"{{msg.payload[1].key}}","min":"0","max":"80000","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":770,"y":320,"wires":[],"info":"# h1 Heading 8-)"},{"id":"8dfa8b92.b80a58","type":"ui_text","z":"b0c1d592.40c9b8","group":"98ad6404.0f5d38","order":1,"width":0,"height":0,"name":"","label":"{{msg.payload[0].parts.key}} :","format":"{{msg.payload[0].key}}","layout":"row-left","x":770,"y":240,"wires":[\*],"info":"`ui_{msg.payload[0].parts.key}`"},{"id":"f52c9088.7d7c1","type":"mqtt-broker","z":"","name":"loadprofileout","broker":"localhost","port":"1884","tls":"","clientid":"caa9f223-0c0d-4a27-9fe5-0311949d3145","usetls":false,"compatmode":true,"keepalive":"60","cleansession":true,"birthTopic":"Demo","birthQos":"0","birthPayload":"","closeTopic":"","closeQos":"0","closePayload":"","willTopic":"","willQos":"0","willPayload":""},{"id":"98ad6404.0f5d38","type":"ui_group","z":"","name":"Load Profile Data EM","tab":"6c03b571.83fb1c","disp":true,"width":"10","collapse":false},{"id":"6c03b571.83fb1c","type":"ui_tab","z":"","name":"Load Profile","icon":"dashboard","order":1,"disabled":false,"hidden":false}]
mqtt string:
{"d":{"DatetimeLP":"1/23/2018 0:30","LP12":"450","LP14":"860","LP24":"1000"}}