| | |
| | | return R.status(placeService.save(place)); |
| | | } |
| | | |
| | | /** |
| | | * 自定义新增/修改 |
| | | * @param placeVO |
| | | * @return |
| | | */ |
| | | @PostMapping("/add") |
| | | public R add(@RequestBody PlaceVO placeVO){ |
| | | return R.status(placeService.addVO(placeVO)); |
| | | return R.status(placeService.addOrUpdate(placeVO)); |
| | | } |
| | | |
| | | /** |
| | |
| | | @ApiOperation(value = "修改", notes = "传入place") |
| | | public R update(@Valid @RequestBody PlaceEntity place) { |
| | | return R.status(placeService.updateById(place)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 自定义修改 |
| | | * @param placeVO |
| | | * @return |
| | | */ |
| | | @PostMapping("/updatePlace") |
| | | public R updatePlace(@RequestBody PlaceVO placeVO){ |
| | | return R.status(placeService.updatePlace(placeVO)); |
| | | } |
| | | |
| | | /** |
| | |
| | | ExcelUtil.save(file, placeImporter, PlaceAndRelExcel.class); |
| | | return R.success("操作成功"); |
| | | } |
| | | |
| | | /** |
| | | * 场所数据处理-用户信息(场所负责人信息写入到场所表) |
| | | */ |
| | | @GetMapping("/placeUserHandle") |
| | | public R placeUserHandle() { |
| | | return R.data(placeService.placeUserHandle()); |
| | | } |
| | | |
| | | /** |
| | | * 场所标签数据处理 |
| | | */ |
| | | @GetMapping("/placeLabelHandle") |
| | | public R placeLabelHandle() { |
| | | return R.data(placeService.placeLabelHandle()); |
| | | } |
| | | } |