Docs:
Since the version 4.1 dataProcessor can work with JSON responses.
Since version 4.1 of DHTMLX library dataProcessor can be used not only with dhtmlxConnector, but also with server-side REST API.
REST API returns a JSON object, thus giving dataProcessor the ability to work with JSON responses.
To set the REST mode, use the setTransactionMode() function with the REST parameter.
Question:
JSON responses works only in REST mode, or in POST too?
If possible send JSON response to dataProcessor, what format it will be?
Hello,
the JSON responses works in all modes.
Generally, the response should contain the same info as a regular xml response, i.e action, sid, tid values
{ "action":"inserted", "sid":122111234, "tid":5}
However it now should work correctly if you return any arbitrary object - in case a response object does not contain these properties, the client-side component will assume the values from it’s current state