The request sent by the client was syntactically incorrect意思嘛,google翻译一下

通过日志不难看出,是由参数不匹配造成的。

所以对于Date日期转换问题解决方法是

 

在相应的controller中添加如下代码:

@InitBinder
protected void initBinder(WebDataBinder binder) {
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
binder.registerCustomEditor(Date.class, new CustomDateEditor(dateFormat, true));
}

 

当然,也不乏别的类型造成的,根据个人情况而定吧。。。

相关文章:

  • 2021-05-28
  • 2021-07-26
  • 2021-04-09
  • 2021-07-01
  • 2021-10-11
猜你喜欢
  • 2021-06-22
  • 2022-12-23
  • 2022-12-23
  • 2021-06-18
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案