springboot传参
- 传入数组
@PostMapping("/delUsers")
public JSONResult delUsers(@RequestParam List<String> userIds) {
int i = userMapper.deleteBatchIds(userIds);
return new JSONResult(i);
}
- 传入数组
@PostMapping("/downloadUser")
@ResponseBody
public void downloadUser(HttpServletResponse response, @RequestBody List<String> list) {
reture null;
}
- 传入文件
@PostMapping(value = "/importUser")
@ApiOperation(value = "批量导入", notes = "批量导入")
public JSONResult importUser(@RequestParam(value = "file") MultipartFile multiFile){
return null
}