From b67c8cbe236608c0ebb8de73314827b19e151676 Mon Sep 17 00:00:00 2001 From: zhengyf Date: Tue, 26 Nov 2024 17:39:48 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=BD=E7=9F=A5=EF=BC=9A1=E3=80=81=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E9=92=89=E9=92=89=E6=97=A5=E5=BF=97=E8=AE=B0=E5=BD=95?= =?UTF-8?q?=E6=8F=92=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../DingCallBackServicePluginInitializer.java | 93 +++++++++++++++++++ 1 file changed, 93 insertions(+) create mode 100644 buildpackage/src/main/java/com/hzya/frame/plugin/lets/plugin/dingtalk/DingCallBackServicePluginInitializer.java diff --git a/buildpackage/src/main/java/com/hzya/frame/plugin/lets/plugin/dingtalk/DingCallBackServicePluginInitializer.java b/buildpackage/src/main/java/com/hzya/frame/plugin/lets/plugin/dingtalk/DingCallBackServicePluginInitializer.java new file mode 100644 index 00000000..51aecfb4 --- /dev/null +++ b/buildpackage/src/main/java/com/hzya/frame/plugin/lets/plugin/dingtalk/DingCallBackServicePluginInitializer.java @@ -0,0 +1,93 @@ +package com.hzya.frame.plugin.lets.plugin.dingtalk; + +import cn.hutool.core.lang.Assert; +import cn.hutool.json.JSONUtil; +import com.alibaba.fastjson.JSONObject; +import com.aliyun.dingtalkoauth2_1_0.models.GetAccessTokenResponseBody; +import com.aliyun.dingtalkworkflow_1_0.models.GetProcessInstanceResponse; +import com.aliyun.dingtalkworkflow_1_0.models.GetProcessInstanceResponseBody; +import com.dingtalk.api.response.OapiV2UserGetResponse; +import com.hzya.frame.base.PluginBaseEntity; +import com.hzya.frame.plugin.lets.constant.OverallConstant; +import com.hzya.frame.plugin.lets.constant.ProfilesActiveConstant; +import com.hzya.frame.plugin.lets.dao.IArapDjzbDao; +import com.hzya.frame.plugin.lets.dingtalk.dao.IDingU8cBillDao; +import com.hzya.frame.plugin.lets.dingtalk.entity.DingU8cBillEntity; +import com.hzya.frame.plugin.lets.dingtalk.utils.DingTalkUtils; +import com.hzya.frame.plugin.lets.entity.ArapDjzbEntity; +import com.hzya.frame.plugin.lets.util.SaveOrUpdateBusinessLogUtil; +import com.hzya.frame.plugin.lets.util.pushData.Attribute; +import com.hzya.frame.plugin.lets.util.pushData.PushU8CByApiCode; +import com.hzya.frame.plugin.lets.util.pushData.ZTResult; +import com.hzya.frame.sysnew.integtationTaskLivingDetails.dao.IIntegrationTaskLivingDetailsDao; +import com.hzya.frame.sysnew.integtationTaskLivingDetails.entity.IntegrationTaskLivingDetailsEntity; +import com.hzya.frame.web.entity.BaseResult; +import com.hzya.frame.web.entity.JsonResultEntity; +import org.apache.commons.httpclient.HttpClient; +import org.apache.commons.httpclient.methods.PostMethod; +import org.apache.commons.httpclient.methods.RequestEntity; +import org.apache.commons.httpclient.methods.StringRequestEntity; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.stereotype.Service; + +import java.io.IOException; +import java.time.LocalDate; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.concurrent.locks.ReentrantLock; + +/** + * 仅作查看 + */ +@Service("DingCallBackService") +public class DingCallBackServicePluginInitializer extends PluginBaseEntity { + Logger logger = LoggerFactory.getLogger(DingCallBackServicePluginInitializer.class); + + @Autowired + private IIntegrationTaskLivingDetailsDao iIntegrationTaskLivingDetailsDao; + + @Autowired + private SaveOrUpdateBusinessLogUtil saveOrUpdateBusinessLogUtil; + @Autowired + private IDingU8cBillDao dingU8cBillDao; + + @Override + public void initialize() { + logger.info(getPluginLabel() + "執行初始化方法initialize()"); + } + + @Override + public void destroy() { + logger.info(getPluginLabel() + "執行銷毀方法destroy()"); + } + + @Override + public String getPluginId() { + return "dingtalk.DingCallBackServicePluginInitializer"; + } + + @Override + public String getPluginName() { + return "丽知:钉钉回调日志"; + } + + @Override + public String getPluginLabel() { + return "丽知:钉钉回调日志"; + } + + @Override + public String getPluginType() { + return "1"; + } + + @Override + public JsonResultEntity executeBusiness(JSONObject requestJson) throws Exception { + return BaseResult.getSuccessMessageEntity("插件执行成功"); + } +}