| | |
| | | import com.boying.service.StreetReRoadService; |
| | | import com.boying.service.StreetService; |
| | | import com.boying.util.LngLatUtil; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import lombok.RequiredArgsConstructor; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | |
| | | @RestController |
| | | @RequestMapping("ffzf/street") |
| | | @RequiredArgsConstructor |
| | | @Tag(description = "ffzf/street" , name = "街道统计" ) |
| | | public class StreetController { |
| | | |
| | | |
| | |
| | | private final StreetLogoService streetLogoService; |
| | | |
| | | @PostMapping("/findPage") |
| | | @Operation(summary = "分页查询" , description = "分页查询" ) |
| | | public Object findPage(Page page, Street street) { |
| | | QueryWrapper<Street> wrapper = new QueryWrapper<>(); |
| | | wrapper.lambda() |
| | |
| | | } |
| | | |
| | | @PostMapping("/save") |
| | | @Operation(summary = "新增街道" , description = "新增街道" ) |
| | | public Object save(Street street) { |
| | | QueryWrapper<Street> wrapper = new QueryWrapper<>(); |
| | | wrapper.lambda() |
| | |
| | | } |
| | | |
| | | @PostMapping("/save2") |
| | | @Operation(summary = "新增路" , description = "新增路" ) |
| | | public Object save2(StreetReRoad streetReRoad) { |
| | | streetReRoadService.saveOrUpdate(streetReRoad); |
| | | return R.ok(); |
| | |
| | | |
| | | |
| | | @PostMapping("/delete") |
| | | @Operation(summary = "删除街" , description = "删除街" ) |
| | | public Object delete(Long id) { |
| | | streetService.removeById(id); |
| | | return R.ok(); |
| | | } |
| | | |
| | | @PostMapping("/delete2") |
| | | @Operation(summary = "删除路" , description = "删除路" ) |
| | | public Object delete2(Long id) { |
| | | streetReRoadService.removeById(id); |
| | | return R.ok(); |
| | | } |
| | | |
| | | @GetMapping("/findById") |
| | | @Operation(summary = "根据id查询(APP)" , description = "根据id查询(APP)" ) |
| | | public Object findById(Long id,int type) { |
| | | if(type==0){ |
| | | QueryWrapper<StreetReRoad> roadQueryWrapper = new QueryWrapper<>(); |
| | |
| | | } |
| | | |
| | | @GetMapping("/findList") |
| | | @Operation(summary = "查询所有街道和路" , description = "查询所有街道和路" ) |
| | | public Object findAll() { |
| | | Map<String,Object> map = new HashMap<>(); |
| | | QueryWrapper<Street> wrapper = new QueryWrapper<>(); |
| | |
| | | } |
| | | |
| | | @GetMapping("/findList2") |
| | | @Operation(summary = "查询所有街道" , description = "查询所有街道" ) |
| | | public Object findAll2() { |
| | | return R.ok(streetService.list()); |
| | | } |
| | | |
| | | @PostMapping("findLogo") |
| | | @Operation(summary = "查询所有街道违章" , description = "查询所有街道违章" ) |
| | | public Object findLogo(String lng ,String lat) { |
| | | List<StreetLogo> all = streetLogoService.list(); |
| | | List<StreetLogo> all2 = new ArrayList<>(); |