Hi,
I've just found a problem with my application that probably appear some time ago (I assume that after upgrade to SmartGWT 2.4).
From the start.
I'm using modified RestDataSource with my own transformResponse() method. That's because I've got only PHP on server side.
I was using this method to show a special error that not concern specific fields. I was just showing an error message by SC.warn() and setting status as:
Unfortunately it doesn't work any more and another dialog appears with:
I've tried to add errors information on server side or even on client side with:
In JSON response errors were set correctly.
My question is how to set this error message when setErrors() doesn't work in this case. I've tried also other RPC statuses with same results.
I cannot find docs about purpose and expected behaviour with each of this statuses. Maybe you can direct me to this.
Maybe problem is in other place. From start I call from code:
So in fact there is no form that could show an error. Maybe here is a problem.
Thanks for any help.
I've just found a problem with my application that probably appear some time ago (I assume that after upgrade to SmartGWT 2.4).
From the start.
I'm using modified RestDataSource with my own transformResponse() method. That's because I've got only PHP on server side.
I was using this method to show a special error that not concern specific fields. I was just showing an error message by SC.warn() and setting status as:
Code:
response.setStatus(RPCResponse.STATUS_FAILURE);
Code:
Server returned FAILURE with no error message.
Code:
JSONArray errors = XMLTools.selectObjects(jsonData, "/response/errors"); response.setErrors(errors.getJavaScriptObject());
My question is how to set this error message when setErrors() doesn't work in this case. I've tried also other RPC statuses with same results.
I cannot find docs about purpose and expected behaviour with each of this statuses. Maybe you can direct me to this.
Maybe problem is in other place. From start I call from code:
Code:
listGrid.addData(record, , new DSCallback() {...}) ;
Thanks for any help.
Comment