From cdfa3d41a2e9cbc3019d9c244ca30b09f2de6f20 Mon Sep 17 00:00:00 2001
From: nidapeng <jp@doumee.com>
Date: 星期六, 20 四月 2024 15:25:37 +0800
Subject: [PATCH] 工作调度
---
server/dmvisit_admin/src/main/java/com/doumee/api/business/HkSyncController.java | 26 +++++++-------------------
1 files changed, 7 insertions(+), 19 deletions(-)
diff --git a/server/dmvisit_admin/src/main/java/com/doumee/api/business/HkSyncController.java b/server/dmvisit_admin/src/main/java/com/doumee/api/business/HkSyncController.java
index 80aef2c..2de1007 100644
--- a/server/dmvisit_admin/src/main/java/com/doumee/api/business/HkSyncController.java
+++ b/server/dmvisit_admin/src/main/java/com/doumee/api/business/HkSyncController.java
@@ -16,6 +16,7 @@
import com.doumee.service.business.impl.hksync.HkSyncPushServiceImpl;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
@@ -46,7 +47,7 @@
@PreventRepeat
@ApiOperation("銆愭捣搴枫�戝叏閲忓悓姝ラ棬绂佽澶囨帴鍙�")
@PostMapping("/syncDevices")
-// @RequiresPermissions("business:hksync:device")
+ @RequiresPermissions("business:hksync:device")
public ApiResponse syncHkDevices(@RequestBody AcsDeviceListRequest param) {
String result = hkSyncDeviceService.syncHkDevices(param);
return ApiResponse.success(result);
@@ -54,7 +55,7 @@
@PreventRepeat
@ApiOperation("銆愭捣搴枫�戝叏閲忓悓姝ュ仠杞﹀簱鎺ュ彛")
@PostMapping("/syncParks")
-// @RequiresPermissions("business:hksync:park")
+ @RequiresPermissions("business:hksync:park")
public ApiResponse syncHkParks(@RequestBody ParkListRequest param) {
String result = hkSyncParkService.syncHkParks(param);
return ApiResponse.success(result);
@@ -62,39 +63,26 @@
@PreventRepeat
@ApiOperation("銆愭捣搴枫�戝叏閲忓悓姝ヨ瀹㈡潈闄愮粍鎺ュ彛")
@PostMapping("/syncPrivilege")
-// @RequiresPermissions("business:hksync:privilege")
+ @RequiresPermissions("business:hksync:privilege")
public ApiResponse syncPrivilege(@RequestBody PrivilegeGroupRequest param) {
String result = hkSyncPrivilegeService.syncPrivilege(param);
return ApiResponse.success(result);
}
- @PreventRepeat
+// @PreventRepeat
@ApiOperation("銆愭捣搴枫�戦棬绂佷簨浠惰闃呮帹閫佸鎺ュ鐞嗘帴鍙�")
@PostMapping("/push/acs")
public ApiResponse pushAcs( HttpServletRequest request,@RequestBody EventAcsRequest param, HttpServletResponse response) {
- /* try {
- BufferedReader br = new BufferedReader(new InputStreamReader(request.getInputStream(),"UTF-8"));
- String line = null;
- StringBuffer sb = new StringBuffer();
- while (true) {
- if (!((line = br.readLine()) != null)) break;
-
- sb.append(line);
- }
- System.out.println(sb.toString());
- } catch (IOException e) {
- throw new RuntimeException(e);
- }*/
String result = hkSyncPushService.dealAcsEvent(param,response);
return ApiResponse.success(result);
}
- @PreventRepeat
+// @PreventRepeat
@ApiOperation("銆愭捣搴枫�戣瀹簨浠惰闃呮帹閫佸鎺ュ鐞嗘帴鍙�")
@PostMapping("/push/visit")
public ApiResponse pushVisit(@RequestBody EventVisitRequest param, HttpServletResponse response) {
String result = hkSyncPushService.dealVisitEvent(param,response);
return ApiResponse.success(result);
}
- @PreventRepeat
+// @PreventRepeat
@ApiOperation("銆愭捣搴枫�戝仠杞﹀満浜嬩欢璁㈤槄鎺ㄩ�佸鎺ュ鐞嗘帴鍙�")
@PostMapping("/push/parks")
public ApiResponse pushParks(@RequestBody EventParkRequest param, HttpServletResponse response) {
--
Gitblit v1.9.3