|
@@ -1,5 +1,6 @@
|
|
|
package com.fdkankan.tracking.controller;
|
|
|
|
|
|
+import com.alibaba.fastjson.JSON;
|
|
|
import com.fdkankan.tracking.service.TrackingService;
|
|
|
import com.fdkankan.tracking.vo.TrackingParamVo;
|
|
|
import com.fdkankan.web.controller.BaseController;
|
|
@@ -11,6 +12,8 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
import java.io.IOException;
|
|
|
+import java.nio.charset.StandardCharsets;
|
|
|
+import java.util.Map;
|
|
|
|
|
|
@RestController
|
|
|
@RequestMapping("/log")
|
|
@@ -54,4 +57,10 @@ public class TrackingController extends BaseController {
|
|
|
// return ResultData.ok();
|
|
|
// }
|
|
|
|
|
|
+ @PostMapping("/saveBeacon")
|
|
|
+ public ResultData saveBeacon(@RequestBody String params) throws IOException {
|
|
|
+ TrackingParamVo param = JSON.parseObject(params, TrackingParamVo.class);
|
|
|
+ return trackingService.saveLog(param, request);
|
|
|
+ }
|
|
|
+
|
|
|
}
|