|
|
@@ -0,0 +1,77 @@
|
|
|
+package com.tzld.piaoquan.api.controller.wecom.thirdpart;
|
|
|
+
|
|
|
+import com.tzld.piaoquan.api.job.wecom.thirdpart.WeComAccountJob;
|
|
|
+import com.tzld.piaoquan.api.job.wecom.thirdpart.WeComCreateRoomJob;
|
|
|
+import com.tzld.piaoquan.api.job.wecom.thirdpart.WeComSendMsgJob;
|
|
|
+import com.tzld.piaoquan.api.job.wecom.thirdpart.WeComUserDetailJob;
|
|
|
+import com.tzld.piaoquan.growth.common.common.base.CommonResponse;
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.web.bind.annotation.GetMapping;
|
|
|
+import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
+
|
|
|
+@Slf4j
|
|
|
+@RestController
|
|
|
+@RequestMapping("/wecom/thirdpart/job")
|
|
|
+public class WeComThirdPartyJobController {
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ WeComSendMsgJob weComSendMsgJob;
|
|
|
+ @Autowired
|
|
|
+ WeComAccountJob weComAccountJob;
|
|
|
+ @Autowired
|
|
|
+ WeComUserDetailJob weComUserDetailJob;
|
|
|
+ @Autowired
|
|
|
+ WeComCreateRoomJob weComCreateRoomJob;
|
|
|
+
|
|
|
+ @GetMapping("/autoSendAppMsg")
|
|
|
+ public CommonResponse<Void> autoSendAppMsg() {
|
|
|
+ weComSendMsgJob.autoSendAppMsg(null);
|
|
|
+ return CommonResponse.success();
|
|
|
+ }
|
|
|
+
|
|
|
+ @GetMapping("/autoOpenSendStatusJob")
|
|
|
+ public CommonResponse<Void> autoOpenSendStatusJob() {
|
|
|
+ weComSendMsgJob.autoOpenSendStatusJob(null);
|
|
|
+ return CommonResponse.success();
|
|
|
+ }
|
|
|
+
|
|
|
+ @GetMapping("/randomRoomSendTimeJob")
|
|
|
+ public CommonResponse<Void> randomRoomSendTimeJob() {
|
|
|
+ weComSendMsgJob.randomRoomSendTimeJob(null);
|
|
|
+ return CommonResponse.success();
|
|
|
+ }
|
|
|
+
|
|
|
+ @GetMapping("/checkAccountOnline")
|
|
|
+ public CommonResponse<Void> checkAccountOnline() {
|
|
|
+ weComAccountJob.checkAccountOnline(null);
|
|
|
+ return CommonResponse.success();
|
|
|
+ }
|
|
|
+
|
|
|
+ @GetMapping("/syncUserDetail")
|
|
|
+ public CommonResponse<Void> syncUserDetail() {
|
|
|
+ weComUserDetailJob.syncUserDetail(null);
|
|
|
+ return CommonResponse.success();
|
|
|
+ }
|
|
|
+
|
|
|
+ @GetMapping("/syncRoomDetail")
|
|
|
+ public CommonResponse<Void> syncRoomDetail() {
|
|
|
+ weComUserDetailJob.syncRoomDetail(null);
|
|
|
+ return CommonResponse.success();
|
|
|
+ }
|
|
|
+
|
|
|
+ @GetMapping("/autoCreateRoom")
|
|
|
+ public CommonResponse<Void> autoCreateRoom() {
|
|
|
+ weComCreateRoomJob.autoCreateRoomJob(null);
|
|
|
+ return CommonResponse.success();
|
|
|
+ }
|
|
|
+
|
|
|
+ @GetMapping("/autoAddRoomUser")
|
|
|
+ public CommonResponse<Void> autoAddRoomUser() {
|
|
|
+ weComCreateRoomJob.autoAddRoomUserJob(null);
|
|
|
+ return CommonResponse.success();
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+}
|