From 88e6c9fc74ccd1560f6e4c21588403d1e02351dc Mon Sep 17 00:00:00 2001 From: PoffyZhang <99775271@qq.com> Date: Wed, 5 Jul 2023 10:02:51 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=89=E5=A4=A9=E4=B8=8D=E5=AE=A1=E6=89=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pmapi/ding/controller/DingInfoPullController.java | 5 ++++- .../com/ningdatech/pmapi/ding/task/EmployeeBatchGetTask.java | 11 +++++++++++ .../ningdatech/pmapi/sys/controller/SysProcDefController.java | 7 ------- 3 files changed, 15 insertions(+), 8 deletions(-) diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/ding/controller/DingInfoPullController.java b/pmapi/src/main/java/com/ningdatech/pmapi/ding/controller/DingInfoPullController.java index 0c781e9..e44bf86 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/ding/controller/DingInfoPullController.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/ding/controller/DingInfoPullController.java @@ -87,5 +87,8 @@ public class DingInfoPullController { System.out.println(JSON.toJSONString(forEntity)); } - + @GetMapping("/getToken") + public String getToken() { + return employeeBatchGetTask.getToken(); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/ding/task/EmployeeBatchGetTask.java b/pmapi/src/main/java/com/ningdatech/pmapi/ding/task/EmployeeBatchGetTask.java index 0c71f11..7c991d8 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/ding/task/EmployeeBatchGetTask.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/ding/task/EmployeeBatchGetTask.java @@ -53,6 +53,9 @@ public class EmployeeBatchGetTask { private ZwddClient zwddClient; @Autowired + private ZwddAuthClient zwddAuthClient; + + @Autowired private IDingOrganizationService iDingOrganizationService; @Autowired @@ -466,4 +469,12 @@ public class EmployeeBatchGetTask { getEmployeeByCode(employee.getEmployeeCode()); } } + + /** + * 获取token + */ + public String getToken() { + GenericResult accessToken = zwddClient.getAccessToken(); + return accessToken.getData(); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/sys/controller/SysProcDefController.java b/pmapi/src/main/java/com/ningdatech/pmapi/sys/controller/SysProcDefController.java index b760e46..e6b077b 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/sys/controller/SysProcDefController.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/sys/controller/SysProcDefController.java @@ -72,11 +72,4 @@ public class SysProcDefController { public String deploy(@Validated @PathVariable String formId) { return processModelService.deployProcess(formId,null); } - - @ApiOperation(value = "流程初始化", notes = "流程初始化") - @GetMapping("/process/init") - @WebLog("系统流程初始化") - public String processInit() { - return menuManage.init(); - } }