Do not know why, the front-end display all the data items are not wrong, only the time that one is very strange, is a series of numbers, and this number in the database can not find ...
Then I debug the backend from the service to the controller, and found that the data are not wrong, take is time ah.
Baidu later know that the original back in the back of the JSON data, with its own serialization mechanism will turn the time into a long number, as shown above.
And then it's going to be a thing to use:
@JsonFormat, its role is to automatically convert date object data into the correct formatted string when the parameter is out.
Effect:
And then through the degrees Niang know, there is an annotation
@DateTimeFormat
This is used to convert the foreground to the background string variable to the date type. The request message only needs to pass in the YYYYMMDDHHMMSS string and is automatically converted to date type data
However, there is also information that @JsonFormat can not only complete the background to the foreground parameter transfer type conversion, but also to achieve the foreground to background type conversion. When Content-type is Application/json, the type conversion is preferred using the pattern of @jsonformat. Instead of using @datetimeformat for type conversions.
The question about the entry is not studied here, there is time to study it later.
About the problem of javadate data returning to the front-end variable numbers