| | |
| | | import com.mzl.flower.dto.request.film.FilmLocationDTO; |
| | | import com.mzl.flower.dto.request.film.FilmLocationQueryDTO; |
| | | import com.mzl.flower.dto.response.film.FilmLocationVO; |
| | | import com.mzl.flower.dto.response.film.FilmWorksVO; |
| | | import com.mzl.flower.service.film.FilmLocationService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.validation.constraints.NotNull; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * 影视拍摄场地信息表前端控制器 |
| | |
| | | public ResponseEntity<ReturnDataDTO<Page<FilmLocationVO>>> getFilmLocationList(Page page, FilmLocationQueryDTO dto) { |
| | | return returnData(R.SUCCESS.getCode(), filmLocationService.queryPage(dto, page)); |
| | | } |
| | | |
| | | @GetMapping("/filmLocation/getTop3") |
| | | @ApiOperation(value = "影视拍摄场地前三", httpMethod = "GET") |
| | | public ResponseEntity<ReturnDataDTO<List<FilmLocationVO>>> getFilmLocationListTop3() { |
| | | return returnData(R.SUCCESS.getCode(), filmLocationService.getFilmLocationListTop3()); |
| | | } |
| | | |
| | | |
| | | @GetMapping(value = "/filmLocation/delete") |
| | | @ApiOperation(value = "删除影视拍摄场地 ", httpMethod = "GET", notes = "ID") |
| | |
| | | filmLocationService.batchMerge(dto); |
| | | return returnData(R.SUCCESS.getCode(), null); |
| | | } |
| | | |
| | | @PostMapping("/filmLocation/delete/batch") |
| | | @ApiOperation(value = "批量删除", notes = "批量删除") |
| | | public ResponseEntity<ReturnDataDTO> batchDelete(@Validated @RequestBody BatchDTO dto) { |
| | | filmLocationService.batchDelete(dto); |
| | | return returnData(R.SUCCESS.getCode(),null); |
| | | } |
| | | |
| | | @GetMapping("/filmLocation/related") |
| | | @ApiOperation(value = "景点对应的影视作品", notes = "景点对应的影视作品") |
| | | public ResponseEntity<ReturnDataDTO<List<FilmWorksVO>>> related(@NotNull(message = "id不能为空") Long locationId) { |
| | | return returnData(R.SUCCESS.getCode(), filmLocationService.related(locationId)); |
| | | } |
| | | |
| | | } |