-
Notifications
You must be signed in to change notification settings - Fork 3
/
Node-RED-QR.json
1 lines (1 loc) · 27.4 KB
/
Node-RED-QR.json
1
[{"id":"afd2b4e.4b8f8c8","type":"ui_button","z":"2681cbba.29fd6c","name":"","group":"2a51926e.a79cbe","order":0,"width":"3","height":"1","passthru":false,"label":"Event","color":"","bgcolor":"","icon":"","payload":"1","payloadType":"str","topic":"","x":210,"y":155.79160690307617,"wires":[["4e36d32e.33993c","2c5f5c82.46473c","3de6c14a.a9f29e","9d8db15b.c760b8"]]},{"id":"8d6cc793.d10e18","type":"ui_button","z":"2681cbba.29fd6c","name":"","group":"28947b90.eab64c","order":0,"width":"3","height":"1","passthru":false,"label":"Event","color":"","bgcolor":"","icon":"","payload":"2","payloadType":"str","topic":"","x":203.33333206176758,"y":241.62496376037598,"wires":[["4e36d32e.33993c","e322b88a.b17b6","c28d1b94.152bb8","4ce36421.f9c894"]]},{"id":"ca01cf19.094bd8","type":"ui_button","z":"2681cbba.29fd6c","name":"","group":"41ba1c7c.9382e4","order":0,"width":"3","height":"1","passthru":false,"label":"Event","color":"","bgcolor":"","icon":"","payload":"3","payloadType":"str","topic":"","x":179.43750762939453,"y":477.62499141693115,"wires":[["4e36d32e.33993c","7638a53e.db38bc","8cc6d947.b07698","8ae98fc1.d18d7"]]},{"id":"a1fccea8.616d08","type":"ui_button","z":"2681cbba.29fd6c","name":"","group":"600a36a5.c46b68","order":0,"width":"3","height":"1","passthru":false,"label":"Event","color":"","bgcolor":"","icon":"","payload":"4","payloadType":"str","topic":"","x":184.93753051757812,"y":712.6250371932983,"wires":[["4e36d32e.33993c","fa6f90c0.47d99","4a8090d5.343768","e1f6d60b.45b19"]]},{"id":"30e2042e.44cc5c","type":"ui_button","z":"2681cbba.29fd6c","name":"","group":"39b61ce0.5b039c","order":0,"width":"3","height":"1","passthru":false,"label":"Event","color":"","bgcolor":"","icon":"","payload":"5","payloadType":"str","topic":"","x":178.93753051757812,"y":866.1250495910645,"wires":[["4e36d32e.33993c","7b7796d.be1f9e8","305ec868.b05188","52d8c9fc.79c2"]]},{"id":"d99e05ef.1bd388","type":"ui_button","z":"2681cbba.29fd6c","name":"","group":"e7ed3285.f385a","order":0,"width":"3","height":"1","passthru":false,"label":"Event","color":"","bgcolor":"","icon":"","payload":"6","payloadType":"str","topic":"","x":160.9375114440918,"y":1016.6250486373901,"wires":[["4e36d32e.33993c","f6c9d1da.4159e8","9aa71b6b.8f8f18","a40cd380.d57028"]]},{"id":"4e36d32e.33993c","type":"ui_slider","z":"2681cbba.29fd6c","name":"","label":"Staus","group":"1ce705a9.113f2a","order":2,"width":"18","height":"1","passthru":true,"topic":"","min":0,"max":"7","step":1,"x":499.5000419616699,"y":562.1249647140503,"wires":[[]]},{"id":"f29ce96f.61b988","type":"ui_button","z":"2681cbba.29fd6c","name":"","group":"cc6ad5ac.cab58","order":4,"width":"3","height":"1","passthru":false,"label":"Event","color":"","bgcolor":"","icon":"","payload":"7","payloadType":"str","topic":"","x":158.9375343322754,"y":1238.6250095367432,"wires":[["4e36d32e.33993c","26a84c5b.a9b874","b78dd704.50889","51d3c654.b43b18"]]},{"id":"2c5f5c82.46473c","type":"ui_text","z":"2681cbba.29fd6c","group":"1ce705a9.113f2a","order":1,"width":"3","height":"1","name":"","label":"Step","format":"{{msg.payload}}","layout":"row-center","x":512.5000381469727,"y":165.62494468688965,"wires":[]},{"id":"e322b88a.b17b6","type":"ui_text","z":"2681cbba.29fd6c","group":"1ce705a9.113f2a","order":3,"width":"2","height":"1","name":"","label":"Step","format":"{{msg.payload}}","layout":"row-left","x":494.2500190734863,"y":361.6249752044678,"wires":[]},{"id":"7638a53e.db38bc","type":"ui_text","z":"2681cbba.29fd6c","group":"1ce705a9.113f2a","order":4,"width":"2","height":"1","name":"","label":"Step","format":"{{msg.payload}}","layout":"row-center","x":481.6875305175781,"y":605.124942779541,"wires":[]},{"id":"fa6f90c0.47d99","type":"ui_text","z":"2681cbba.29fd6c","group":"1ce705a9.113f2a","order":0,"width":"2","height":"1","name":"","label":"Step","format":"{{msg.payload}}","layout":"row-center","x":472.68756103515625,"y":734.1250534057617,"wires":[]},{"id":"7b7796d.be1f9e8","type":"ui_text","z":"2681cbba.29fd6c","group":"1ce705a9.113f2a","order":0,"width":"3","height":"1","name":"","label":"Step","format":"{{msg.payload}}","layout":"row-center","x":443.6876220703125,"y":903.1250553131104,"wires":[]},{"id":"f6c9d1da.4159e8","type":"ui_text","z":"2681cbba.29fd6c","group":"1ce705a9.113f2a","order":0,"width":"2","height":"1","name":"","label":"Step","format":"{{msg.payload}}","layout":"row-center","x":427.18759536743164,"y":1096.6250324249268,"wires":[]},{"id":"26a84c5b.a9b874","type":"ui_text","z":"2681cbba.29fd6c","group":"1ce705a9.113f2a","order":0,"width":"2","height":"1","name":"","label":"Step","format":"{{msg.payload}}","layout":"row-center","x":444.18762969970703,"y":1281.1252174377441,"wires":[]},{"id":"5570e12f.dbfd4","type":"ui_text","z":"2681cbba.29fd6c","group":"7be1b8f8.b71c5","order":0,"width":"18","height":"1","name":"Input to BC","label":"","format":"{{msg.payload}}","layout":"row-left","x":784.9791564941406,"y":530.5971994400024,"wires":[]},{"id":"3b616c64.8245cc","type":"ui_text","z":"2681cbba.29fd6c","group":"e1a113be.1dbdc8","order":0,"width":"25","height":"2","name":"Output of Blockchain","label":"","format":"{{msg.payload}}","layout":"row-left","x":1456.7986335754395,"y":261.40980434417725,"wires":[]},{"id":"d228ab41.d66d28","type":"ui_button","z":"2681cbba.29fd6c","name":"","group":"1ce705a9.113f2a","order":0,"width":"1","height":"1","passthru":false,"label":"Reset","color":"","bgcolor":"","icon":"","payload":"1","payloadType":"str","topic":"","x":78.2499885559082,"y":390.93057441711426,"wires":[["4e36d32e.33993c","ea99d97e.fde858","100a04fa.761c6b","a9d5963f.59cd78","8048d97f.45488"]]},{"id":"46d40d0e.73a6c4","type":"ui_gauge","z":"2681cbba.29fd6c","name":"","group":"cc6ad5ac.cab58","order":2,"width":"3","height":"2","gtype":"wave","title":"","label":"","format":"{{value}}","min":0,"max":"200","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":1720.2366104125977,"y":318.8890209197998,"wires":[]},{"id":"c28d1b94.152bb8","type":"function","z":"2681cbba.29fd6c","name":"write trnx1 JSON","func":"msg.payload = {\n \"jsonrpc\": \"2.0\",\n \"method\": \"invoke\",\n \"params\": {\n \"type\": 1,\n \"chaincodeID\": {\n \"name\": \"6b8191709a0711b840804a834c232d6a6c5d30a32c1cd8f9a6c30420f7f9dc55cf42fde6171c562cd46acc8a758c1448cd38f379c6bcdfe333b95cfc1550ec1d\"\n },\n \"ctorMsg\": {\n \"function\": \"addDeleteMile\",\n \"args\": [\n \"1\",\n\t\t\"10:10\",\n\t\t\"477511\",\n\t\t\"user_type1_1\",\n\t\t\"25\",\n\t\t\"add\",\n\t\t\"add\",\n\t\t\"IBM India\"\n\t\t]\n },\n \"secureContext\": \"user_type1_1\"\n },\n \"id\": 1\n};\nreturn msg;\n","outputs":1,"noerr":0,"x":540.9219207763672,"y":244.12999629974365,"wires":[["1e5e1178.049067"]]},{"id":"f3f351a2.dcd718","type":"http request","z":"2681cbba.29fd6c","name":"BC Invoke URL","method":"POST","ret":"obj","url":"https://93fa8437b97b4616ba5c7a5e95b988fa-vp0.us.blockchain.ibm.com:5002/chaincode","tls":"","x":789.4219512939453,"y":130.13002586364746,"wires":[["549381f6.329cc8","3b616c64.8245cc"]]},{"id":"549381f6.329cc8","type":"debug","z":"2681cbba.29fd6c","name":"","active":true,"console":"false","complete":"false","x":932.9932708740234,"y":48.701358795166016,"wires":[]},{"id":"3de6c14a.a9f29e","type":"function","z":"2681cbba.29fd6c","name":"write asset JSON","func":"msg.payload =\n{\n \"jsonrpc\": \"2.0\",\n \"method\": \"invoke\",\n \"params\": {\n \"type\": 1,\n \"chaincodeID\": {\n \"name\": \"6b8191709a0711b840804a834c232d6a6c5d30a32c1cd8f9a6c30420f7f9dc55cf42fde6171c562cd46acc8a758c1448cd38f379c6bcdfe333b95cfc1550ec1d\"\n },\n \"ctorMsg\": {\n \"function\": \"registerAsset\",\n \"args\": [\n \"477511\",\n\t\t\"Iron\",\n\t\t\"HeavyItems\",\n\t\t\"ABC\",\n\t\t\"CBA\",\n\t\t\"01/01/2010\",\n\t\t\"mafcode4321\",\n\t\t\"India\",\n\t\t\"Gurgaon\",\n\t\t\"Haryana\",\n\t\t\"120011\",\n\t\t\"Cargo77\"\n\t\t]\n },\n \"secureContext\": \"user_type1_0\"\n },\n \"id\": 1\n};\nreturn msg;\n","outputs":1,"noerr":0,"x":507.6718978881836,"y":51.437453269958496,"wires":[["f3f351a2.dcd718"]]},{"id":"a9d5963f.59cd78","type":"function","z":"2681cbba.29fd6c","name":"get points","func":"msg.payload ={\n \"jsonrpc\": \"2.0\",\n \"method\": \"query\",\n \"params\": {\n \"type\": 1,\n \"chaincodeID\": {\n \"name\": \"6b8191709a0711b840804a834c232d6a6c5d30a32c1cd8f9a6c30420f7f9dc55cf42fde6171c562cd46acc8a758c1448cd38f379c6bcdfe333b95cfc1550ec1d\"\n },\n \"ctorMsg\": {\n \"function\": \"getMile\",\n \"args\": [\n\t \"477511\" \n ]\n },\n \"secureContext\": \"user_type1_1\"\n },\n \"id\": 0\n};\nreturn msg;\n","outputs":1,"noerr":0,"x":1366.6016654968262,"y":104.91413497924805,"wires":[["c4dc4878.1812b8"]]},{"id":"c4dc4878.1812b8","type":"http request","z":"2681cbba.29fd6c","name":"BC Query URL","method":"POST","ret":"obj","url":"https://93fa8437b97b4616ba5c7a5e95b988fa-vp0.us.blockchain.ibm.com:5002/chaincode","tls":"","x":1384.9220581054688,"y":183.55861473083496,"wires":[["ad8b3ed5.c38358"]]},{"id":"91c229fc.593e9","type":"debug","z":"2681cbba.29fd6c","name":"","active":true,"console":"false","complete":"false","x":1712.1684188842773,"y":399.4805212020874,"wires":[]},{"id":"ea99d97e.fde858","type":"function","z":"2681cbba.29fd6c","name":"get asset","func":"msg.payload ={\n \"jsonrpc\": \"2.0\",\n \"method\": \"query\",\n \"params\": {\n \"type\": 1,\n \"chaincodeID\": {\n \"name\": \"6b8191709a0711b840804a834c232d6a6c5d30a32c1cd8f9a6c30420f7f9dc55cf42fde6171c562cd46acc8a758c1448cd38f379c6bcdfe333b95cfc1550ec1d\"\n },\n \"ctorMsg\": {\n \"function\": \"getAsset\",\n \"args\": [\n\t \"477511\" \n ]\n },\n \"secureContext\": \"user_type1_1\"\n },\n \"id\": 0\n};\nreturn msg;\n","outputs":1,"noerr":0,"x":1459.8594131469727,"y":507.5585250854492,"wires":[["2f260fd9.62b06"]]},{"id":"47d39fe5.79776","type":"inject","z":"2681cbba.29fd6c","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"x":1340.8634033203125,"y":422.6444721221924,"wires":[["ea99d97e.fde858"]]},{"id":"2f260fd9.62b06","type":"http request","z":"2681cbba.29fd6c","name":"BC Query URL","method":"POST","ret":"obj","url":"https://93fa8437b97b4616ba5c7a5e95b988fa-vp0.us.blockchain.ibm.com:5002/chaincode","tls":"","x":1452.6172103881836,"y":606.2030696868896,"wires":[["d9320662.0c89d","17263f72.864a71"]]},{"id":"d9320662.0c89d","type":"debug","z":"2681cbba.29fd6c","name":"","active":true,"console":"false","complete":"false","x":1663.8634567260742,"y":606.1249580383301,"wires":[]},{"id":"9d8db15b.c760b8","type":"template","z":"2681cbba.29fd6c","name":"Inpur Args","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"\"args\": [\n \"477511\",\n\t\t\"Iron\",\n\t\t\"HeavyItems\",\n\t\t\"ABC\",\n\t\t\"CBA\",\n\t\t\"01/01/2010\",\n\t\t\"mafcode4321\",\n\t\t\"India\",\n\t\t\"Gurgaon\",\n\t\t\"Haryana\",\n\t\t\"120011\",\n\t\t\"Cargo77\"\n\t\t]","x":529.8056106567383,"y":106.93051147460938,"wires":[["5570e12f.dbfd4"]]},{"id":"2769cfde.529b98","type":"ui_template","z":"2681cbba.29fd6c","group":"cc6ad5ac.cab58","name":"Read Container History","order":3,"width":"3","height":"3","format":"<img src=\"https://github.com/AmarMundi/Monitoring/blob/master/QR.png?raw=true\" />","storeOutMessages":true,"fwdInMessages":true,"templateScope":"local","x":1464.2569465637207,"y":1184.8540382385254,"wires":[[]]},{"id":"4b9d538a.f60424","type":"ui_template","z":"2681cbba.29fd6c","group":"3365ff37.5e6ed8","name":"container logo","order":0,"width":"4","height":"2","format":"<img src=\"https://github.com/AmarMundi/Monitoring/blob/master/blockchain_businessusecases_provenance.png?raw=true\" />","storeOutMessages":true,"fwdInMessages":true,"templateScope":"local","x":1169.4792556762695,"y":1184.4025621414185,"wires":[[]]},{"id":"1e5e1178.049067","type":"http request","z":"2681cbba.29fd6c","name":"BC Invoke URL","method":"POST","ret":"obj","url":"https://93fa8437b97b4616ba5c7a5e95b988fa-vp0.us.blockchain.ibm.com:5002/chaincode","tls":"","x":811.041618347168,"y":244.40274620056152,"wires":[["6e17263a.3f993","3b616c64.8245cc"]]},{"id":"4ce36421.f9c894","type":"template","z":"2681cbba.29fd6c","name":"Input Args","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"\"args\": [\n \"1\",\n\t\t\"10:10\",\n\t\t\"477511\",\n\t\t\"user_type1_1\",\n\t\t\"25\",\n\t\t\"add\",\n\t\t\"add\",\n\t\t\"IBM India\"\n\t\t]","x":529.7917098999023,"y":304.95826721191406,"wires":[["5570e12f.dbfd4"]]},{"id":"6e17263a.3f993","type":"debug","z":"2681cbba.29fd6c","name":"","active":true,"console":"false","complete":"false","x":941.8124732971191,"y":324.7568883895874,"wires":[]},{"id":"8cc6d947.b07698","type":"function","z":"2681cbba.29fd6c","name":"write trnx2 JSON","func":"msg.payload = {\n \"jsonrpc\": \"2.0\",\n \"method\": \"invoke\",\n \"params\": {\n \"type\": 1,\n \"chaincodeID\": {\n \"name\": \"6b8191709a0711b840804a834c232d6a6c5d30a32c1cd8f9a6c30420f7f9dc55cf42fde6171c562cd46acc8a758c1448cd38f379c6bcdfe333b95cfc1550ec1d\"\n },\n \"ctorMsg\": {\n \"function\": \"addDeleteMile\",\n \"args\": [\n \"2\",\n\t\t\"10:11\",\n\t\t\"477511\",\n\t\t\"user_type1_1\",\n\t\t\"25\",\n\t\t\"add\",\n\t\t\"add\",\n\t\t\"IBM SL\"\n\t\t]\n },\n \"secureContext\": \"user_type1_1\"\n },\n \"id\": 1\n};\nreturn msg;\n","outputs":1,"noerr":0,"x":509.0415802001953,"y":438.4027490615845,"wires":[["38142995.f986d6"]]},{"id":"38142995.f986d6","type":"http request","z":"2681cbba.29fd6c","name":"BC Invoke URL","method":"POST","ret":"obj","url":"https://93fa8437b97b4616ba5c7a5e95b988fa-vp0.us.blockchain.ibm.com:5002/chaincode","tls":"","x":781.0416030883789,"y":438.4027347564697,"wires":[["1a4d8b6b.7ef68d","3b616c64.8245cc"]]},{"id":"1a4d8b6b.7ef68d","type":"debug","z":"2681cbba.29fd6c","name":"","active":true,"console":"false","complete":"false","x":1051.0416221618652,"y":442.40270137786865,"wires":[]},{"id":"8ae98fc1.d18d7","type":"template","z":"2681cbba.29fd6c","name":"Input Args","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"\"args\": [\n \"2\",\n\t\t\"10:11\",\n\t\t\"477511\",\n\t\t\"user_type1_1\",\n\t\t\"25\",\n\t\t\"add\",\n\t\t\"add\",\n\t\t\"IBM SL\"\n\t\t]","x":515.0416564941406,"y":498.4027509689331,"wires":[["5570e12f.dbfd4"]]},{"id":"1bd16199.0a7746","type":"http request","z":"2681cbba.29fd6c","name":"BC Query URL","method":"POST","ret":"obj","url":"https://93fa8437b97b4616ba5c7a5e95b988fa-vp0.us.blockchain.ibm.com:5002/chaincode","tls":"","x":1321.0415725708008,"y":844.4027042388916,"wires":[["5ea0c961.98a5f8","d365b897.553578","a7951a38.1f79f8"]]},{"id":"b78dd704.50889","type":"function","z":"2681cbba.29fd6c","name":"Query All JSON","func":"msg.payload ={\n \"jsonrpc\": \"2.0\",\n \"method\": \"query\",\n \"params\": {\n \"type\": 1,\n \"chaincodeID\": {\n \"name\": \"6b8191709a0711b840804a834c232d6a6c5d30a32c1cd8f9a6c30420f7f9dc55cf42fde6171c562cd46acc8a758c1448cd38f379c6bcdfe333b95cfc1550ec1d\"\n },\n \"ctorMsg\": {\n \"function\": \"getAllTransaction\",\n \"args\": [\n\t \"477511\",\n ]\n },\n \"secureContext\": \"user_type1_1\"\n },\n \"id\": 0\n};\nreturn msg;\n","outputs":1,"noerr":0,"x":1087.7081985473633,"y":846.0693912506104,"wires":[["1bd16199.0a7746"]]},{"id":"5ea0c961.98a5f8","type":"debug","z":"2681cbba.29fd6c","name":"","active":true,"console":"false","complete":"false","x":1595.8034400939941,"y":847.3193798065186,"wires":[]},{"id":"8ac8c164.f1f95","type":"inject","z":"2681cbba.29fd6c","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"x":875.7082061767578,"y":898.9027624130249,"wires":[["b78dd704.50889"]]},{"id":"a7951a38.1f79f8","type":"function","z":"2681cbba.29fd6c","name":"","func":"return {payload:msg.payload.result.message};","outputs":1,"noerr":0,"x":1279.9978408813477,"y":725.0633182525635,"wires":[["4a713501.85580c","3b616c64.8245cc"]]},{"id":"4a713501.85580c","type":"debug","z":"2681cbba.29fd6c","name":"","active":true,"console":"false","complete":"false","x":1580.8869552612305,"y":724.7017459869385,"wires":[]},{"id":"ada0aab3.e6d0f","type":"http in","z":"2681cbba.29fd6c","name":"","url":"/bc","method":"get","swaggerDoc":"","x":988.4478225708008,"y":703.4938306808472,"wires":[["b78dd704.50889"]]},{"id":"d365b897.553578","type":"http response","z":"2681cbba.29fd6c","name":"","x":1571.2200164794922,"y":789.6110649108887,"wires":[]},{"id":"ad8b3ed5.c38358","type":"function","z":"2681cbba.29fd6c","name":"","func":"return {payload:msg.payload.result.message};","outputs":1,"noerr":0,"x":1579.0418148040771,"y":184.40274620056152,"wires":[["55f51ce8.5046bc"]]},{"id":"55f51ce8.5046bc","type":"json","z":"2681cbba.29fd6c","name":"","x":1733.7919540405273,"y":182.94441413879395,"wires":[["352f99a8.99e786"]]},{"id":"352f99a8.99e786","type":"function","z":"2681cbba.29fd6c","name":"","func":"return {payload:msg.payload.totalPoint};","outputs":1,"noerr":0,"x":1725.812515258789,"y":250.95830535888672,"wires":[["46d40d0e.73a6c4","91c229fc.593e9","8368b4f0.523788"]]},{"id":"51d3c654.b43b18","type":"template","z":"2681cbba.29fd6c","name":"Input Args","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"\"args\": [\n\t \"477511\",\n ]","x":459.81945037841797,"y":1220.9584379196167,"wires":[["5570e12f.dbfd4"]]},{"id":"100a04fa.761c6b","type":"template","z":"2681cbba.29fd6c","name":"Input Args","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"\"args\": [\n\t \"477511\",\n ]","x":223.80559539794922,"y":312.944393157959,"wires":[["5570e12f.dbfd4"]]},{"id":"17263f72.864a71","type":"function","z":"2681cbba.29fd6c","name":"","func":"return {payload:msg.payload.result.status};","outputs":1,"noerr":0,"x":1659.041582107544,"y":524.4027080535889,"wires":[["3b616c64.8245cc"]]},{"id":"8368b4f0.523788","type":"template","z":"2681cbba.29fd6c","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"{{payload}}","x":1577.7917671203613,"y":106.95828056335449,"wires":[["b591788a.a8eac8"]]},{"id":"b591788a.a8eac8","type":"ui_text","z":"2681cbba.29fd6c","group":"cc6ad5ac.cab58","order":1,"width":0,"height":0,"name":"","label":"Items Carried: ","format":"{{msg.payload}}","layout":"row-left","x":1759.8125114440918,"y":106.03468132019043,"wires":[]},{"id":"ab1fb243.3ba288","type":"ui_text","z":"2681cbba.29fd6c","group":"cc6ad5ac.cab58","order":0,"width":"4","height":"2","name":"","label":"Port Weather","format":"{{msg.payload}}","layout":"col-center","x":1659.0415954589844,"y":1004.1249408721924,"wires":[]},{"id":"965c80e5.38c4f8","type":"inject","z":"2681cbba.29fd6c","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"x":987.0416107177734,"y":1100.1249265670776,"wires":[["8048d97f.45488"]]},{"id":"8048d97f.45488","type":"http request","z":"2681cbba.29fd6c","name":"Get Current Weather","method":"GET","ret":"obj","url":"https://d921603e-eebd-4894-b6a6-d7d98ec0b889:[email protected]/api/weather/v1/geocode/28.430327/77.103229/observations.json?language=en-US","tls":"","x":1193.0416107177734,"y":1027.1248970031738,"wires":[["3b4d133e.adc264","a616d1fa.28e49"]]},{"id":"78f8b57c.217c64","type":"debug","z":"2681cbba.29fd6c","name":"","active":true,"console":"false","complete":"false","x":1657.0415954589844,"y":936.6248607635498,"wires":[]},{"id":"3b4d133e.adc264","type":"function","z":"2681cbba.29fd6c","name":"Extract Temp","func":"global.set(\"weather\",msg.payload.observation.temp); \nreturn {payload:msg.payload.observation.temp};","outputs":1,"noerr":0,"x":1223.0416564941406,"y":925.1249752044678,"wires":[["7fd8ede1.557b64"]]},{"id":"7fd8ede1.557b64","type":"template","z":"2681cbba.29fd6c","name":"Temp","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"Temperature: {{payload}} degree Fahrenheit!","x":1417.041633605957,"y":923.1249475479126,"wires":[["78f8b57c.217c64","ab1fb243.3ba288"]]},{"id":"a616d1fa.28e49","type":"function","z":"2681cbba.29fd6c","name":"Extract phrase","func":"global.set(\"weather\",msg.payload.observation.wx_phrase); \nreturn {payload:msg.payload.observation.wx_phrase};","outputs":1,"noerr":0,"x":1437.0415954589844,"y":1107.6247291564941,"wires":[["d7ae4c1c.72a958"]]},{"id":"d7ae4c1c.72a958","type":"template","z":"2681cbba.29fd6c","name":"Condition","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"Condition: {{payload}}","x":1448.0416564941406,"y":1028.1248111724854,"wires":[["78f8b57c.217c64","2dbb9fae.2b2198"]]},{"id":"2dbb9fae.2b2198","type":"ui_text","z":"2681cbba.29fd6c","group":"cc6ad5ac.cab58","order":0,"width":"3","height":"2","name":"","label":"","format":"{{msg.payload}}","layout":"col-center","x":1647.0417289733887,"y":1072.402668952942,"wires":[]},{"id":"4a8090d5.343768","type":"function","z":"2681cbba.29fd6c","name":"write trnx3 JSON","func":"msg.payload = {\n \"jsonrpc\": \"2.0\",\n \"method\": \"invoke\",\n \"params\": {\n \"type\": 1,\n \"chaincodeID\": {\n \"name\": \"6b8191709a0711b840804a834c232d6a6c5d30a32c1cd8f9a6c30420f7f9dc55cf42fde6171c562cd46acc8a758c1448cd38f379c6bcdfe333b95cfc1550ec1d\"\n },\n \"ctorMsg\": {\n \"function\": \"addDeleteMile\",\n \"args\": [\n \"3\",\n\t\t\"11:11\",\n\t\t\"477511\",\n\t\t\"user_type1_1\",\n\t\t\"25\",\n\t\t\"add\",\n\t\t\"add\",\n\t\t\"IBM SG\"\n\t\t]\n },\n \"secureContext\": \"user_type1_1\"\n },\n \"id\": 1\n};\nreturn msg;\n","outputs":1,"noerr":0,"x":465.0416717529297,"y":670.4027442932129,"wires":[["e8ec2867.3613c"]]},{"id":"e8ec2867.3613c","type":"http request","z":"2681cbba.29fd6c","name":"BC Invoke URL","method":"POST","ret":"obj","url":"https://93fa8437b97b4616ba5c7a5e95b988fa-vp0.us.blockchain.ibm.com:5002/chaincode","tls":"","x":765.041633605957,"y":624.4027442932129,"wires":[["e6794ff4.d68258","3b616c64.8245cc"]]},{"id":"e6794ff4.d68258","type":"debug","z":"2681cbba.29fd6c","name":"","active":true,"console":"false","complete":"false","x":1003.7985458374023,"y":624.7360649108887,"wires":[]},{"id":"e1f6d60b.45b19","type":"template","z":"2681cbba.29fd6c","name":"Input Args","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"\"args\": [\n \"3\",\n\t\t\"11:11\",\n\t\t\"477511\",\n\t\t\"user_type1_1\",\n\t\t\"25\",\n\t\t\"add\",\n\t\t\"add\",\n\t\t\"IBM SG\"\n\t\t]","x":471.04161834716797,"y":790.4027070999146,"wires":[["5570e12f.dbfd4"]]},{"id":"305ec868.b05188","type":"function","z":"2681cbba.29fd6c","name":"write trnx4 JSON","func":"msg.payload = {\n \"jsonrpc\": \"2.0\",\n \"method\": \"invoke\",\n \"params\": {\n \"type\": 1,\n \"chaincodeID\": {\n \"name\": \"6b8191709a0711b840804a834c232d6a6c5d30a32c1cd8f9a6c30420f7f9dc55cf42fde6171c562cd46acc8a758c1448cd38f379c6bcdfe333b95cfc1550ec1d\"\n },\n \"ctorMsg\": {\n \"function\": \"addDeleteMile\",\n \"args\": [\n \"4\",\n\t\t\"11:12\",\n\t\t\"477511\",\n\t\t\"user_type1_1\",\n\t\t\"25\",\n\t\t\"add\",\n\t\t\"add\",\n\t\t\"IBM HK\"\n\t\t]\n },\n \"secureContext\": \"user_type1_1\"\n },\n \"id\": 1\n};\nreturn msg;\n","outputs":1,"noerr":0,"x":481.04164123535156,"y":842.4026985168457,"wires":[["3d570c5f.7fc7ec"]]},{"id":"52d8c9fc.79c2","type":"template","z":"2681cbba.29fd6c","name":"Input Args","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"\"args\": [\n \"4\",\n\t\t\"11:12\",\n\t\t\"477511\",\n\t\t\"user_type1_1\",\n\t\t\"25\",\n\t\t\"add\",\n\t\t\"add\",\n\t\t\"IBM HK\"\n\t\t]","x":457.04164123535156,"y":968.4026985168457,"wires":[["5570e12f.dbfd4"]]},{"id":"3d570c5f.7fc7ec","type":"http request","z":"2681cbba.29fd6c","name":"BC Invoke URL","method":"POST","ret":"obj","url":"https://93fa8437b97b4616ba5c7a5e95b988fa-vp0.us.blockchain.ibm.com:5002/chaincode","tls":"","x":737.0416107177734,"y":808.4026985168457,"wires":[["e7d2be23.24a168","3b616c64.8245cc"]]},{"id":"e7d2be23.24a168","type":"debug","z":"2681cbba.29fd6c","name":"","active":true,"console":"false","complete":"false","x":795.8055648803711,"y":706.7500352859497,"wires":[]},{"id":"9aa71b6b.8f8f18","type":"function","z":"2681cbba.29fd6c","name":"write trnx4 JSON","func":"msg.payload = {\n \"jsonrpc\": \"2.0\",\n \"method\": \"invoke\",\n \"params\": {\n \"type\": 1,\n \"chaincodeID\": {\n \"name\": \"6b8191709a0711b840804a834c232d6a6c5d30a32c1cd8f9a6c30420f7f9dc55cf42fde6171c562cd46acc8a758c1448cd38f379c6bcdfe333b95cfc1550ec1d\"\n },\n \"ctorMsg\": {\n \"function\": \"addDeleteMile\",\n \"args\": [\n \"5\",\n\t\t\"11:13\",\n\t\t\"477511\",\n\t\t\"user_type1_1\",\n\t\t\"25\",\n\t\t\"add\",\n\t\t\"add\",\n\t\t\"IBM AUS\"\n\t\t]\n },\n \"secureContext\": \"user_type1_1\"\n },\n \"id\": 1\n};\nreturn msg;\n","outputs":1,"noerr":0,"x":475.04164123535156,"y":1040.4026374816895,"wires":[["ba561839.98984"]]},{"id":"a40cd380.d57028","type":"template","z":"2681cbba.29fd6c","name":"Input Args","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"\"args\": [\n \"5\",\n\t\t\"11:13\",\n\t\t\"477511\",\n\t\t\"user_type1_1\",\n\t\t\"25\",\n\t\t\"add\",\n\t\t\"add\",\n\t\t\"IBM AUS\"\n\t\t]","x":431.04164123535156,"y":1148.4026374816895,"wires":[["5570e12f.dbfd4"]]},{"id":"ba561839.98984","type":"http request","z":"2681cbba.29fd6c","name":"BC Invoke URL","method":"POST","ret":"obj","url":"https://93fa8437b97b4616ba5c7a5e95b988fa-vp0.us.blockchain.ibm.com:5002/chaincode","tls":"","x":721.0416107177734,"y":982.4026985168457,"wires":[["d671e01b.9f85a","3b616c64.8245cc"]]},{"id":"d671e01b.9f85a","type":"debug","z":"2681cbba.29fd6c","name":"","active":true,"console":"false","complete":"false","x":917.819450378418,"y":1024.7430424690247,"wires":[]},{"id":"2a51926e.a79cbe","type":"ui_group","z":"","name":"Step 1: Parts Commissioned","tab":"18ed9e5f.f62062","order":3,"disp":true,"width":"9"},{"id":"28947b90.eab64c","type":"ui_group","z":"","name":"Step 2: Part Dispatch from MaF","tab":"18ed9e5f.f62062","order":4,"disp":true,"width":"9"},{"id":"41ba1c7c.9382e4","type":"ui_group","z":"","name":"Step 3: Part Arrival at Port 1","tab":"18ed9e5f.f62062","order":5,"disp":true,"width":"9"},{"id":"600a36a5.c46b68","type":"ui_group","z":"","name":"Step 4: Part Departure from Port 1","tab":"18ed9e5f.f62062","order":6,"disp":true,"width":"9"},{"id":"39b61ce0.5b039c","type":"ui_group","z":"","name":"Step 5: Part Arrival at Port 2","tab":"18ed9e5f.f62062","order":7,"disp":true,"width":"9"},{"id":"e7ed3285.f385a","type":"ui_group","z":"","name":"Step 6: Part Departure from Port 2","tab":"18ed9e5f.f62062","order":8,"disp":true,"width":"9"},{"id":"1ce705a9.113f2a","type":"ui_group","z":"","name":"Status","tab":"18ed9e5f.f62062","order":2,"disp":true,"width":"19"},{"id":"cc6ad5ac.cab58","type":"ui_group","z":"","name":"Step 7: Part Arrival at Warehouse","tab":"18ed9e5f.f62062","order":9,"disp":true,"width":"7"},{"id":"7be1b8f8.b71c5","type":"ui_group","z":"","name":"Input to Blockchain","tab":"18ed9e5f.f62062","order":10,"disp":true,"width":"18"},{"id":"e1a113be.1dbdc8","type":"ui_group","z":"","name":"Output of Blockchain","tab":"18ed9e5f.f62062","order":12,"disp":true,"width":"25"},{"id":"3365ff37.5e6ed8","type":"ui_group","z":"","name":"Logo","tab":"18ed9e5f.f62062","order":1,"disp":false,"width":"6"},{"id":"18ed9e5f.f62062","type":"ui_tab","z":"","name":"Provenance: vehicle maintenance","icon":"dashboard","order":2}]