Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [{"id":"200e1c36.5d5ec4","type":"Blockly","z":"f5cadd93.6607b","language":"en","func":"var variableNeeded;\n\n\nflow.set('foo', (JSON.parse('{\"f1\":\"f11\",\"f2\":\"f22\"}')));\nvariableNeeded = Object.keys((flow.get('foo')));\nnode.status({fill:\"blue\", shape:\"ring\", text:variableNeeded});\nmsg['bar'] = (JSON.parse('{\"b1\":\"b11\",\"b2\":\"b22\"}'));\nmsg['bar'] = Object.keys((msg['bar']));\nnode.send([msg]);\nreturn;\n","workspaceXml":"<xml xmlns=\"http://www.w3.org/1999/xhtml\"><variables><variable type=\"\" id=\"K,ACb9/+4t$G=Cadk{MR\">variableNeeded</variable></variables><block type=\"node_object_set\" id=\"Q*13*A~zygn:znmym^Ws\" x=\"13\" y=\"13\"><value name=\"object_field\"><shadow type=\"node_msg\" id=\"+O{24VL2oo3WX+mEs1m8\"></shadow><block type=\"node_flow_memory\" id=\"R(z1IL5Gzs1)Z7eSF?bd\"></block></value><value name=\"field_name\"><shadow type=\"text\" id=\"7f6*YdiPloV+xe0obvwI\"><field name=\"TEXT\">foo</field></shadow></value><value name=\"value_field\"><shadow type=\"text\" id=\"dSO-vi!wO@Me#t1,Ac*z\"><field name=\"TEXT\"></field></shadow><block type=\"object_from_json\" id=\"Y+90wz:aUw1UjddT@:*`\"><value name=\"JSON\"><shadow type=\"text\" id=\"7~+XORM/cgX=r~7^$+hW\"><field name=\"TEXT\">{\"f1\":\"f11\",\"f2\":\"f22\"}</field></shadow></value></block></value><next><block type=\"variables_set\" id=\"1-g3aP%x6[{o:aFIqn-r\"><field name=\"VAR\" id=\"K,ACb9/+4t$G=Cadk{MR\" variabletype=\"\">variableNeeded</field><value name=\"VALUE\"><block type=\"object_keys\" id=\"q4%rFoo1!AbagqE6N?o7\"><value name=\"object_input\"><shadow type=\"node_msg\" id=\"o};Bd6I{DaS:D*^o=xd+\"></shadow><block type=\"node_object_get\" id=\"9I$P#?.{GxTGko;znibR\"><field name=\"action\">GET</field><value name=\"object\"><shadow type=\"node_msg\" id=\"d](n|VA5t5eM,BIkWw4Z\"></shadow><block type=\"node_flow_memory\" id=\";H+6#v/|SSKF-IS:v!bJ\"></block></value><value name=\"field_name\"><shadow type=\"text\" id=\"l_0Ao4V56je:AjLQLM+b\"><field name=\"TEXT\">foo</field></shadow></value></block></value></block></value><next><block type=\"node_status\" id=\"4CRCXK9v}k)Y-{be{q-n\"><field name=\"COLOUR\">#0000FF</field><field name=\"SHAPE\">RING</field><value name=\"TEXT_INPUT\"><shadow type=\"text\" id=\"AlLn7TW^nMOcX5yu0~[D\"><field name=\"TEXT\"></field></shadow><block type=\"variables_get\" id=\";d@cPf6aJ%1Gy.`Absnj\"><field name=\"VAR\" id=\"K,ACb9/+4t$G=Cadk{MR\" variabletype=\"\">variableNeeded</field></block></value><next><block type=\"node_object_set\" id=\"#9!!*zCan[+,T9Hr$nB{\"><value name=\"object_field\"><shadow type=\"node_msg\" id=\"+O{24VL2oo3WX+mEs1m8\"></shadow></value><value name=\"field_name\"><shadow type=\"text\" id=\"!M@(w3PoEN]k|7+%=sIf\"><field name=\"TEXT\">bar</field></shadow></value><value name=\"value_field\"><shadow type=\"text\" id=\"dSO-vi!wO@Me#t1,Ac*z\"><field name=\"TEXT\"></field></shadow><block type=\"object_from_json\" id=\"+TwB)MDsxF~#V?_3%A]E\"><value name=\"JSON\"><shadow type=\"text\" id=\"vJ$Y%Rc6-FE]I.J,H2?C\"><field name=\"TEXT\">{\"b1\":\"b11\",\"b2\":\"b22\"}</field></shadow></value></block></value><next><block type=\"node_object_set\" id=\":vsr^`_TH%XUI5uucZwI\"><value name=\"object_field\"><shadow type=\"node_msg\" id=\"xvV-yD_B;x(C+*@:i/4v\"></shadow></value><value name=\"field_name\"><shadow type=\"text\" id=\"f:]3i?w}D34JyY@Nx7Hd\"><field name=\"TEXT\">bar</field></shadow></value><value name=\"value_field\"><shadow type=\"text\" id=\"dSO-vi!wO@Me#t1,Ac*z\"><field name=\"TEXT\"></field></shadow><block type=\"object_keys\" id=\"IHjQoo(Ee5pYBGrGbC5x\"><value name=\"object_input\"><shadow type=\"node_msg\" id=\"@Z8QCW@Fkeq_8su/^{Ou\"></shadow><block type=\"node_object_get\" id=\"=ttOU8,*aaqg4,4r/)-,\"><field name=\"action\">GET</field><value name=\"object\"><shadow type=\"node_msg\" id=\"MN39,W1f}K75?M@wjXBQ\"></shadow></value><value name=\"field_name\"><shadow type=\"text\" id=\"^RR[!dt#=DyI^wK},[NR\"><field name=\"TEXT\">bar</field></shadow></value></block></value></block></value><next><block type=\"node_send\" id=\"o/|X/(mQ(Pn]0#B3%{/S\"><field name=\"OUTPUT_NR\">1</field><value name=\"MESSAGE_INPUT\"><shadow type=\"node_msg\" id=\"PQCHGg6Rdp`%Ym]}Lb=0\"></shadow></value><next><block type=\"node_return\" id=\"(*aB4-GuN)VRgo;iW5q`\"></block></next></block></next></block></next></block></next></block></next></block></next></block></xml>","outputs":1,"name":"","x":980,"y":120,"wires":[["a815b52a.050dd8"]]},{"id":"c2736ca4.e9298","type":"inject","z":"f5cadd93.6607b","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":740,"y":120,"wires":[["200e1c36.5d5ec4"]]},{"id":"a815b52a.050dd8","type":"debug","z":"f5cadd93.6607b","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","x":1190,"y":120,"wires":[]}]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement