From ad6dfb8323ab40ca8fe4fed94722c755d89c3203 Mon Sep 17 00:00:00 2001 From: jiangping <jp@doumee.com> Date: 星期三, 28 二月 2024 15:14:47 +0800 Subject: [PATCH] 整理 --- server/dmvisit_admin/src/main/java/com/doumee/api/business/HkSyncController.java | 20 ++++---------------- 1 files changed, 4 insertions(+), 16 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..98132b6 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,7 +63,7 @@ @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); @@ -71,19 +72,6 @@ @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); } -- Gitblit v1.9.3