I don"t understand;
Why not all pass strings directly
I don"t understand;
Why not all pass strings directly
different languages can obtain different date formats in the foreground and background, so it may not be possible to parse the date directly to the front end, but the timestamps are all the same.
if your server is in the United States and the string is returned in the time zone of the United States, what will happen to your visit in China?
back-end communication is a timestamp no matter who sends it.
because there are many formats of time, different pages may have different requirements for different times.
for example,
05-8-8 9:17
2005-8-8 9:17:42
August 8, 2005 09:17:42
09:17:42 GMT+08:00
on August 8, 2005, how does the front end know which format you are passing? he cannot parse your string. Why don't you just send the timestamp and convert it from the front end to the format he wants.
as for the front end passing to the backend, in fact, normally, you should also pass a timestamp, but the string you pass is also converted into Date format by Springmvc. If you directly use Servlet to write, the passed string will certainly not be converted into Date.
Previous: A number multiplied by 3 at a time, and multiplied several times will exceed 100.
Next: Vue Project introduces the problem of Abscissa display of echarts Line Chart