| | |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.Arrays; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @Description: 巡查上报 |
| | |
| | | return R.data(patrolReportService.updateById(patrolReport)); |
| | | } |
| | | |
| | | /** |
| | | * 批量编辑 |
| | | */ |
| | | @ApiOperation(value="巡查上报-批量编辑", notes="巡查上报-批量编辑") |
| | | @RequestMapping(value = "/editBatch", method = {RequestMethod.PUT,RequestMethod.POST}) |
| | | public R editBatch(@RequestBody List<PatrolReport> list){ |
| | | return R.data(patrolReportService.customizeUpdateBatchById(list)); |
| | | } |
| | | |
| | | /** |
| | | * 通过id删除 |
| | | * |
| | |
| | | * @return |
| | | */ |
| | | @ApiOperation(value="巡查上报-通过id删除", notes="巡查上报-通过id删除") |
| | | @DeleteMapping(value = "/delete") |
| | | @PostMapping(value = "/delete") |
| | | public R delete(@RequestParam(name="id",required=true) String id) { |
| | | patrolReportService.removeById(id); |
| | | return R.data(patrolReportService.removeById(id)); |
| | |
| | | * @return |
| | | */ |
| | | @ApiOperation(value="巡查上报-批量删除", notes="巡查上报-批量删除") |
| | | @DeleteMapping(value = "/deleteBatch") |
| | | @PostMapping(value = "/deleteBatch") |
| | | public R deleteBatch(@RequestParam(name="ids",required=true) String ids) { |
| | | return R.data(this.patrolReportService.removeByIds(Arrays.asList(ids.split(",")))); |
| | | } |