赞
踩
前后端分离,使用String来post json数据时,有可能会导致无法解析。
Resolved[org.springframework.http.converter.HttpMessageNotReadableException:
JSON parse error: Cannot deserialize value of type java.util.Date
from String “2017-
06-08”: not a valid representation (error: Failed to parse Date value ‘2017-06-08’:
Unparseable date: “2017-06-08”); nested exception iscom.fasterxml.jackson.databind.exc.
InvalidFormatException: Cannot deserialize value of type java.util.Date
from String
“2017-06-08”: not a valid representation (error: Failed to parse Date value ‘2017-06-08’: Unparseable date: “2017-06-08”)
at [Source: (PushbackInputStream); line: 2, column: 9] (through reference chain: com.team.entity.TimeBean[“date”])]
找了很多办法,如:
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。