#1 2017-03-30 13:25:56

emaxx
Member
Registered: 2014-07-03
Posts: 18

JSON DateTime ISO 8601

In Javascript a stringified date looks like
 

  JSON.stringify(new Date(1490875855648))
  "2017-03-30T12:10:55.648Z"

Unfortunately this is not the same with mORMot:
   

  UnixMSTimeToString(1490875855648, True, 'T', 'Z');
  '2017-03-30T:12:10:55.648Z'

 
I suggest to change the value of SynCommons.DTMS_FMT[True] to

'%-%-%%%:%:%.%%'

So it would be conform with ISO 8601, as also mentioned in the comment 'YYYY-MM-DD hh:mm:ss.sssZ'.

Thanks.

Offline

#2 2017-03-30 15:06:14

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,240
Website

Re: JSON DateTime ISO 8601

Fixed by https://synopse.info/fossil/info/e4334bd5b5

Thanks for the report!

Offline

Board footer

Powered by FluxBB