mybatis-plus已经设置时间列为默认插入,但是插入操作仍然输入值导致报错或者输入时间格式不对报错

2021-10-21 13:20:24.268  WARN 5912 --- [nio-8201-exec-4] .w.s.m.s.DefaultHandlerExceptionResolver : Resolved [org.springframework.http.converter.HttpMessageNotReadableException: JSON parse error: Cannot deserialize value of type `java.util.Date` from String "2021-10-21T05:19:10.872Z": expected format "yyyy-MM-dd HH:mm:ss"; nested exception is com.fasterxml.jackson.databind.exc.InvalidFormatException: Cannot deserialize value of type `java.util.Date` from String "2021-10-21T05:19:10.872Z": expected format "yyyy-MM-dd HH:mm:ss"
 at [Source: (PushbackInputStream); line: 5, column: 17] (through reference chain: com.yelin.model.hosp.Hr["createTime"])]

上一篇:Eclipse中添加注释模板


下一篇:C++格式化数字输入字符串的几个办法