lula / ngx-soap

Simple SOAP client for Angular
MIT License
66 stars 61 forks source link

Error parsing body[object Object] #13

Closed yuvanesh10 closed 6 years ago

yuvanesh10 commented 6 years ago

Hey Lula, Sorry to bother you again..,I couldn't able to receive the soap msg what I send from server. now I am getting the following error.

this.jsonResponse = this.client.parseResponseBody(response.text());

any ideas regarding this ? If you have time.,can you have look at this (entire proj) https://gist.github.com/yuvanesh10/2a8c9cf6af659d95dd3cc8ccebfa52c4

Thank you.

My stacktrace

ERROR Error: Error parsing body[object Object] at Client.parseResponseBody (client.js:100) at SafeSubscriber.eval [as _next] (app.component.ts:49) at SafeSubscriber.__tryOrUnsub (Subscriber.js:240) at SafeSubscriber.next (Subscriber.js:187) at Subscriber._next (Subscriber.js:128) at Subscriber.next (Subscriber.js:92) at XMLHttpRequest.onLoad (http.js:1591) at ZoneDelegate.invokeTask (zone.js:421) at Object.onInvokeTask (core.js:4744) at ZoneDelegate.invokeTask (zone.js:420)

lula commented 6 years ago

Hello @yuvanesh10 no worries. What't your response.text()? Is it the expected SOAP response?

yuvanesh10 commented 6 years ago

@lula hey..,yes it is

lula commented 6 years ago

Good 😄! You may want to paste it here so I could check what's wrong?

yuvanesh10 commented 6 years ago

https://gist.github.com/yuvanesh10/2a8c9cf6af659d95dd3cc8ccebfa52c4 the entire project is here

lula commented 6 years ago

To make short the long story: I'll never loose time again studying frameworks I don't know (and that I'm not inclined to study and install just for test either) like strong-soap or arango db. They might be the perfect choice, not for me know, sorry :). unicuique suum.

If you want me to help you with your project, you have those choices:

  1. (preferred) have the project hosted like in a plunker or whatever you prefer so that there's a way I can check it online
  2. bundle the in a way that I can install all dependencies with one command only (npm/yarn, your choice).

Cheers

yuvanesh10 commented 6 years ago

okie perfect !!! I will do it one of those ways

yuvanesh10 commented 6 years ago

@lula sorry to bother..,have solved the error !!! cheers

lula commented 6 years ago

Hello @yuvanesh10 ! Great news! Cheers

yuvanesh10 commented 6 years ago

@lula I have a small question..,If I need to only send the request from client.. should I alter the code from client side ? in other words..,I dont want to get the response back..,just need to post something in database .

P.S I have made changes in my wsdl file(by adding only request operation) and server file..

lula commented 6 years ago

@yuvanesh10 well, if you don't need any response (whatever the http response and/or database operation result are...) you just don't wait for it (promise).