web services - Need help to use node-soap module -


i have make server update device.
asked me use node.js , device send soap request. need check parameters verify version. decided use node-soap module. (the wsdl file use local file)
can't find how recover value of parameters. read node-soap spec, couldn't find how that. :/
here code (i didn't yet because i'm stuck because of this) :

var myservice = {     actiaproxyapi: { //myservice         actiaproxyapi: { //myport               getdata: function(args) { //myfunction                     if (args.i-uitype == "11") {                         var id = args.i-pcidentifiant;                         var reg=new regexp("[ $]+", "g"); //parse string (actually works)                         var tableau=id.split(reg);                          console.log(tableau[4] );                       }                   return {                       name: args.o-podata                    };               }            }       }   };    var xml = require('fs').readfilesync('./wsdl/actiaproxyapi.wsdl', 'utf8'),       server = http.createserver(function(request,response) {           response.end("404: not found: "+request.url);       });    server.listen(8080);   soap.listen(server, '/wsdl', myservice, xml); 

i've found how retrieve arguments' value : instead of args.i-uitype used args["i-uitype"] , , instead of name: args.o-podata :
'tns:getdataresponse': {'o-podata': result}

well hope can other people, because works me !


Comments

Popular posts from this blog

html5 - What is breaking my page when printing? -

html - Unable to style the color of bullets in a list -

c# - must be a non-abstract type with a public parameterless constructor in redis -