HTTP Status 400
来源:互联网 发布:汽车外形设计软件 编辑:程序博客网 时间:2024/06/05 20:35
@RequestMapping(method = RequestMethod.POST, value = "/search")SjesPage<TurnTable> findTurnTables(@RequestParam(value = "startDate", required = false) String startDate, @RequestParam(value = "endDate", required = false) String endDate, Pageable pageable)
当 startDate为null 时候 会报错: HTTP Status 400 - Required String parameter 'xx' is not present
required = false 当 startDate不存在时候赋值 null
解决:
改 required = true,也可以不写, 为空时候 startDate 手动赋值 “ ”
if(StringUtils.isEmpty(startDate)|| StringUtils.isEmpty(endDate)){ return turnTableApiClient.findTurnTables("", "", new PageRequest(page - 1, limit));}
阅读全文
0 0
- HTTP Status 400
- HTTP Status 400
- HTTP Status 400
- HTTP Status 400
- HTTP Status 400
- HTTP Status 400
- HTTP Status 400
- HTTP Status 400
- HTTP Status 400 - 问题集成
- http status 400,http 400,400 错误
- http status 400,http 400,400 错误
- http status 400,http 400,400 错误
- http status
- HTTP::Status
- http status
- HTTP STATUS
- http status
- svn 1.8 unexpected http status 400 ''
- 安卓数据库框架——Realm进阶学习
- TCP的3次握手与4次挥手
- jquery autocomplete 自动完成插件及插件常用属性及项目案例
- MySQL 索引优化
- Java中文所对应的编码区间
- HTTP Status 400
- 创建辅助区域
- An internal error occurred during: "Building workspace". Java heap space
- yii 备份还原数据库
- P-残缺的棋盘
- synchronized和volatile理解
- 动态规划(一)
- linux下python调试
- 【单调队列】51nod 1275 连续子段的差异