对比新文件 |
| | |
| | | package com.lf.server.controller.show; |
| | | |
| | | import com.lf.server.annotation.SysLog; |
| | | import com.lf.server.controller.all.BaseController; |
| | | import com.lf.server.entity.all.ResponseMsg; |
| | | import com.lf.server.service.all.BaseQueryService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | /** |
| | | * 缁煎悎灞曠ず |
| | | * @author WWW |
| | | */ |
| | | @Api(tags = "缁煎悎灞曠ず\\缁煎悎灞曠ず") |
| | | @RestController |
| | | @RequestMapping("/comprehensive") |
| | | public class ComprehensiveController extends BaseController { |
| | | @Autowired |
| | | BaseQueryService baseQueryService; |
| | | |
| | | @SysLog() |
| | | @ApiOperation(value = "鏌ヨ璺綉") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "x1", value = "X1", dataType = "Double", paramType = "query", example = "116.78999"), |
| | | @ApiImplicitParam(name = "y1", value = "Y1", dataType = "Double", paramType = "query", example = "39.9468"), |
| | | @ApiImplicitParam(name = "x2", value = "X2", dataType = "Double", paramType = "query", example = "116.80458"), |
| | | @ApiImplicitParam(name = "y2", value = "Y2", dataType = "Double", paramType = "query", example = "39.94758") |
| | | }) |
| | | @GetMapping(value = "/selectRoute") |
| | | public ResponseMsg<Object> selectRoute(double x1, double y1, double x2, double y2) { |
| | | try { |
| | | String route = baseQueryService.selectRoute(x1, y1, x2, y2); |
| | | |
| | | return success(route); |
| | | } catch (Exception ex) { |
| | | return fail(ex.getMessage(), null); |
| | | } |
| | | } |
| | | } |