I believe the problem is that there is no standard way for json-encoding a
date. In my applications I explicitly convert date strings received from the
server into a JS date object:
var dateJS = new Date(dateStrFromServer);
Cheers,
Fritz
P.S.: You really shouldn't use rpc.callSync() as it
I would recommend to not use date object at all in your code, just use
string and convert to date when you really need to manipulate it. I found
this approach to be much safer. For date manipulation I use moment.
On Wed, Aug 5, 2015 at 8:00 AM, Fritz Zaucker zauc...@oetiker.ch wrote:
I believe
fritz wrote
P.S.: You really shouldn't use rpc.callSync()
of course, is only a ad-hoc example. Thanks for your time Fritz.
Finally I get de Date object.
Some like this send, and receive, all Date objects with the proper
convertions:
qx.io.remote.Rpc.CONVERT_DATES = true;
I believe it was a serious oversight in the JavaScript design, carried over
to the JSON design, that there is no literal form for a Date object. Every
native type in JavaScript other than Date has a literal form.
I was one of the people who worked on that date hack, nearly 10 years ago.
It is not
Hi (sorry the english)
Please, I need some little help about a absurd basic question.
I really really try understand the Qooxdoo 5.0 Date object converter around
Rpc use.
For example I use rpc,
var rpc = new qx.io.remote.Rpc(services/, comp.Prueba);
try {
var r =