|
@@ -0,0 +1,25 @@
|
|
|
+package com.onemap.analyse.controller.analyse;
|
|
|
+
|
|
|
+import com.onemap.analyse.service.ISlopService;
|
|
|
+import com.onemap.common.core.web.domain.RequestResult;
|
|
|
+import com.onemap.common.datasource.annotation.Slave;
|
|
|
+import org.springframework.web.bind.annotation.GetMapping;
|
|
|
+import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
+import org.springframework.web.bind.annotation.RequestParam;
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
+
|
|
|
+import javax.annotation.Resource;
|
|
|
+
|
|
|
+
|
|
|
+@RestController
|
|
|
+@RequestMapping("/slop")
|
|
|
+public class SlopController {
|
|
|
+ @Resource
|
|
|
+ private ISlopService iSlopService;
|
|
|
+
|
|
|
+ @GetMapping("/average")
|
|
|
+ @Slave
|
|
|
+ public RequestResult getAveSlop(@RequestParam(value = "geom") String geom) {
|
|
|
+ return RequestResult.success(iSlopService.getAveSlop(geom));
|
|
|
+ }
|
|
|
+}
|