Skip to content

Commit

Permalink
🍱 商品类目列表接口的参数验证
Browse files Browse the repository at this point in the history
  • Loading branch information
newbee-mall committed Feb 12, 2020
1 parent 32856d7 commit 04e230c
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public String categoriesPage(HttpServletRequest request, @RequestParam("category
@RequestMapping(value = "/categories/list", method = RequestMethod.GET)
@ResponseBody
public Result list(@RequestParam Map<String, Object> params) {
if (StringUtils.isEmpty(params.get("page")) || StringUtils.isEmpty(params.get("limit"))) {
if (StringUtils.isEmpty(params.get("page")) || StringUtils.isEmpty(params.get("limit")) || StringUtils.isEmpty(params.get("categoryLevel")) || StringUtils.isEmpty(params.get("parentId"))) {
return ResultGenerator.genFailResult("参数异常!");
}
PageQueryUtil pageUtil = new PageQueryUtil(params);
Expand Down

0 comments on commit 04e230c

Please sign in to comment.