diff --git a/README.md b/README.md
index fb1556c..7e3f14f 100644
--- a/README.md
+++ b/README.md
@@ -1,3 +1,6 @@
# open-JSD-8974
-JSD-8974 飞书消息推送+单点登录
\ No newline at end of file
+JSD-8974 飞书消息推送+单点登录\
+免责说明:该源码为第三方爱好者提供,不保证源码和方案的可靠性,也不提供任何形式的源码教学指导和协助!\
+仅作为开发者学习参考使用!禁止用于任何商业用途!\
+为保护开发者隐私,开发者信息已隐去!若原开发者希望公开自己的信息,可联系hugh处理。
\ No newline at end of file
diff --git a/plugin.xml b/plugin.xml
new file mode 100644
index 0000000..5d5eb4f
--- /dev/null
+++ b/plugin.xml
@@ -0,0 +1,29 @@
+
+ com.eco.plugin.xxxx.fssso
+
+ yes
+ 1.0.18
+ 10.0
+ 2018-07-31
+ fr.open
+
+
+ com.eco.plugin.xxxx.fssso
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/main/java/com/eco/plugin/xxxx/fssso/config/InitializeMonitor.java b/src/main/java/com/eco/plugin/xxxx/fssso/config/InitializeMonitor.java
new file mode 100644
index 0000000..e43f1d2
--- /dev/null
+++ b/src/main/java/com/eco/plugin/xxxx/fssso/config/InitializeMonitor.java
@@ -0,0 +1,32 @@
+package com.eco.plugin.xxxx.fssso.config;
+
+import com.eco.plugin.xxxx.fssso.dsdd.dsdd.DSDDMsgFormula;
+import com.eco.plugin.xxxx.fssso.dsdd.dsdd.TsBean;
+import com.eco.plugin.xxxx.fssso.dsdd.dsdd.TsEntity;
+import com.eco.plugin.xxxx.fssso.dsdd.dsdd.TsHandler;
+import com.fr.plugin.context.PluginContext;
+import com.fr.plugin.observer.inner.AbstractPluginLifecycleMonitor;
+import com.fr.schedule.extension.report.job.output.formula.FormulaBox;
+import com.fr.schedule.feature.ScheduleOutputActionEntityRegister;
+import com.fr.schedule.feature.output.OutputActionHandler;
+
+/**
+ * @author fr.open
+ * @version 10.0
+ * Created by fr.open on 2018-12-04
+ */
+public class InitializeMonitor extends AbstractPluginLifecycleMonitor {
+ @Override
+ public void afterRun(PluginContext pluginContext) {
+ OutputActionHandler.registerHandler(new TsHandler(), TsBean.class.getName());
+ ScheduleOutputActionEntityRegister.getInstance().addClass(TsEntity.class);
+ FormulaBox.KEY.register(new DSDDMsgFormula());
+ WinkSimpleConfig.getInstance();
+ }
+
+ @Override
+ public void beforeStop(PluginContext pluginContext) {
+ OutputActionHandler.removeOutputHandler(TsBean.class.getName());
+ ScheduleOutputActionEntityRegister.getInstance().removeClass(TsEntity.class);
+ }
+}
diff --git a/src/main/java/com/eco/plugin/xxxx/fssso/config/WinkSimpleConfig.java b/src/main/java/com/eco/plugin/xxxx/fssso/config/WinkSimpleConfig.java
new file mode 100644
index 0000000..8565b4a
--- /dev/null
+++ b/src/main/java/com/eco/plugin/xxxx/fssso/config/WinkSimpleConfig.java
@@ -0,0 +1,186 @@
+package com.eco.plugin.xxxx.fssso.config;
+
+import com.fr.config.*;
+import com.fr.config.holder.Conf;
+import com.fr.config.holder.factory.Holders;
+import com.fr.intelli.record.Focus;
+import com.fr.intelli.record.Original;
+import com.fr.record.analyzer.EnableMetrics;
+
+@Visualization(category = "消息推送及单点登录配置")
+@EnableMetrics
+public class WinkSimpleConfig extends DefaultConfiguration {
+
+ private static volatile WinkSimpleConfig config = null;
+
+ @Focus(id="com.eco.plugin.xxxx.idmsso.config", text = "消息推送及单点登录配置", source = Original.PLUGIN)
+ public static WinkSimpleConfig getInstance() {
+ if (config == null) {
+ config = ConfigContext.getConfigInstance(WinkSimpleConfig.class);
+ }
+ return config;
+ }
+
+ @Identifier(value = "clientId", name = "appid", description = "appid", status = Status.SHOW)
+ private Conf clientId = Holders.simple("");
+
+ @Identifier(value = "secret", name = "secret", description = "secret", status = Status.SHOW)
+ private Conf secret = Holders.simple("");
+
+ @Identifier(value = "index", name = "Plugin-wink_index", description = "Plugin-wink_index", status = Status.SHOW)
+ private Conf index = Holders.simple("");
+
+ @Identifier(value = "authUrl", name = "Plugin-wink_codeurl", description = "Plugin-wink_codeurl", status = Status.SHOW)
+ private Conf authUrl = Holders.simple("");
+
+ @Identifier(value = "tokenUrl", name = "Plugin-wink_tokenurl", description = "Plugin-wink_tokenurl", status = Status.SHOW)
+ private Conf tokenUrl = Holders.simple("");
+
+ @Identifier(value = "userUrl", name = "Plugin-wink_userurl", description = "Plugin-wink_userurl", status = Status.SHOW)
+ private Conf userUrl = Holders.simple("");
+
+ @Identifier(value = "sendMessage", name = "Plugin-wink_sendMessageUrl", description = "Plugin-wink_sendMessageUrl", status = Status.SHOW)
+ private Conf sendMessage = Holders.simple("");
+
+ @Identifier(value = "cancelMessage", name = "Plugin-wink_cancelMessage", description = "Plugin-wink_cancelMessage", status = Status.SHOW)
+ private Conf cancelMessage = Holders.simple("");
+
+ @Identifier(value = "sysdes", name = "Plugin-wink_sysdes", description = "Plugin-wink_sysdes", status = Status.SHOW)
+ private Conf sysdes = Holders.simple("");
+
+ @Identifier(value = "syscode", name = "Plugin-wink_syscode", description = "Plugin-wink_syscode", status = Status.SHOW)
+ private Conf syscode = Holders.simple("");
+
+ @Identifier(value = "mtokenUrl", name = "Plugin-wink_gettokenurl", description = "Plugin-wink_gettokenurl", status = Status.SHOW)
+ private Conf mtokenUrl = Holders.simple("");
+
+ @Identifier(value = "imgUrl", name = "Plugin-wink_imgurl", description = "Plugin-wink_imgurl", status = Status.SHOW)
+ private Conf imgUrl = Holders.simple("");
+
+ @Identifier(value = "username", name = "Plugin-wink_pouser", description = "Plugin-wink_pouser", status = Status.SHOW)
+ private Conf username = Holders.simple("");
+
+ @Identifier(value = "psd", name = "Plugin-wink_popsd", description = "Plugin-wink_popsd", status = Status.SHOW)
+ private Conf psd = Holders.simple("");
+
+
+ public String getSysdes() {
+ return sysdes.get();
+ }
+
+ public void setSysdes(String url) {
+ this.sysdes.set(url);
+ }
+
+ public String getSyscode() {
+ return syscode.get();
+ }
+
+ public void setSyscode(String url) {
+ this.syscode.set(url);
+ }
+
+ public String getSendMessage() {
+ return sendMessage.get();
+ }
+
+ public void setSendMessage(String url) {
+ this.sendMessage.set(url);
+ }
+
+ public String getCancelMessage() {
+ return cancelMessage.get();
+ }
+
+ public void setCancelMessage(String url) {
+ this.cancelMessage.set(url);
+ }
+
+ public String getClientId() {
+ return clientId.get();
+ }
+
+ public void setClientId(String url) {
+ this.clientId.set(url);
+ }
+
+ public String getSecret() {
+ return secret.get();
+ }
+
+ public void setSecret(String url) {
+ this.secret.set(url);
+ }
+
+ public String getAuthUrl() {
+ return authUrl.get();
+ }
+
+ public void setAuthUrl(String url) {
+ this.authUrl.set(url);
+ }
+
+ public String getTokenUrl() {
+ return tokenUrl.get();
+ }
+
+ public void setTokenUrl(String url) {
+ this.tokenUrl.set(url);
+ }
+
+ public String getUserUrl() {
+ return userUrl.get();
+ }
+
+ public void setUserUrl(String url) {
+ this.userUrl.set(url);
+ }
+
+ public String getMtokenUrl() {
+ return mtokenUrl.get();
+ }
+
+ public void setMtokenUrl(String url) {
+ this.mtokenUrl.set(url);
+ }
+
+ public String getUsername() {
+ return username.get();
+ }
+
+ public void setUsername(String url) {
+ this.username.set(url);
+ }
+
+ public String getPsd() {
+ return psd.get();
+ }
+
+ public void setPsd(String url) {
+ this.psd.set(url);
+ }
+
+ public String getIndex() {
+ return index.get();
+ }
+
+ public void setIndex(String url) {
+ this.index.set(url);
+ }
+
+ public String getImgUrl() {
+ return imgUrl.get();
+ }
+
+ public void setImgUrl(String url) {
+ this.imgUrl.set(url);
+ }
+
+ @Override
+ public Object clone() throws CloneNotSupportedException {
+ WinkSimpleConfig cloned = (WinkSimpleConfig) super.clone();
+
+ return cloned;
+ }
+
+}
diff --git a/src/main/java/com/eco/plugin/xxxx/fssso/db/bean/DBEntity.java b/src/main/java/com/eco/plugin/xxxx/fssso/db/bean/DBEntity.java
new file mode 100644
index 0000000..887ee13
--- /dev/null
+++ b/src/main/java/com/eco/plugin/xxxx/fssso/db/bean/DBEntity.java
@@ -0,0 +1,173 @@
+package com.eco.plugin.xxxx.fssso.db.bean;
+
+import com.fr.stable.db.entity.BaseEntity;
+import com.fr.stable.db.entity.TableAssociation;
+import com.fr.third.javax.persistence.Column;
+import com.fr.third.javax.persistence.Table;
+
+/**
+ * @author fr.open
+ * @version 10.0
+ * Created by fr.open on 2021-11-30
+ **/
+@com.fr.third.javax.persistence.Entity
+@Table(name = "plugin_message_info")
+@TableAssociation(associated = true)
+public class DBEntity extends BaseEntity {
+
+ //uuid
+ @Column(name = "uuid")
+ private String uuid = null;
+
+ //系统编码
+ @Column(name = "syscode")
+ private String syscode = null;
+
+ //系统描述
+ @Column(name = "sysdes")
+ private String sysdes = null;
+
+ //发送时间
+ @Column(name = "sendertime")
+ private String sendertime = null;
+
+ //appid
+ @Column(name = "appid")
+ private String appid = null;
+
+ //servicename
+ @Column(name = "servicename")
+ private String servicename = null;
+
+ //content
+ @Column(name = "content")
+ private String content = null;
+
+ //msg_type
+ @Column(name = "msg_type")
+ private String msg_type = null;
+
+ //receive_id
+ @Column(name = "receive_id")
+ private String receive_id = null;
+
+ //receive_id_type
+ @Column(name = "receive_id_type")
+ private String receive_id_type = null;
+
+ //messageid
+ @Column(name = "messageid")
+ private String messageid = null;
+
+ //result
+ @Column(name = "result")
+ private String result = null;
+
+ //issuccess
+ @Column(name = "issuccess")
+ private String issuccess = null;
+
+ public String getUuid() {
+ return uuid;
+ }
+
+ public void setUuid(String uuid) {
+ this.uuid = uuid;
+ }
+
+ public String getSyscode() {
+ return syscode;
+ }
+
+ public void setSyscode(String syscode) {
+ this.syscode = syscode;
+ }
+
+ public String getSysdes() {
+ return sysdes;
+ }
+
+ public void setSysdes(String sysdes) {
+ this.sysdes = sysdes;
+ }
+
+ public String getSendertime() {
+ return sendertime;
+ }
+
+ public void setSendertime(String sendertime) {
+ this.sendertime = sendertime;
+ }
+
+ public String getAppid() {
+ return appid;
+ }
+
+ public void setAppid(String appid) {
+ this.appid = appid;
+ }
+
+ public String getServicename() {
+ return servicename;
+ }
+
+ public void setServicename(String servicename) {
+ this.servicename = servicename;
+ }
+
+ public String getContent() {
+ return content;
+ }
+
+ public void setContent(String content) {
+ this.content = content;
+ }
+
+ public String getMsg_type() {
+ return msg_type;
+ }
+
+ public void setMsg_type(String msg_type) {
+ this.msg_type = msg_type;
+ }
+
+ public String getReceive_id() {
+ return receive_id;
+ }
+
+ public void setReceive_id(String receive_id) {
+ this.receive_id = receive_id;
+ }
+
+ public String getReceive_id_type() {
+ return receive_id_type;
+ }
+
+ public void setReceive_id_type(String receive_id_type) {
+ this.receive_id_type = receive_id_type;
+ }
+
+ public String getMessageid() {
+ return messageid;
+ }
+
+ public void setMessageid(String messageid) {
+ this.messageid = messageid;
+ }
+
+ public String getResult() {
+ return result;
+ }
+
+ public void setResult(String result) {
+ this.result = result;
+ }
+
+ public String getIssuccess() {
+ return issuccess;
+ }
+
+ public void setIssuccess(String issuccess) {
+ this.issuccess = issuccess;
+ }
+}
diff --git a/src/main/java/com/eco/plugin/xxxx/fssso/db/controller/DBController.java b/src/main/java/com/eco/plugin/xxxx/fssso/db/controller/DBController.java
new file mode 100644
index 0000000..8e907cb
--- /dev/null
+++ b/src/main/java/com/eco/plugin/xxxx/fssso/db/controller/DBController.java
@@ -0,0 +1,62 @@
+package com.eco.plugin.xxxx.fssso.db.controller;
+
+import com.eco.plugin.xxxx.fssso.db.bean.DBEntity;
+import com.eco.plugin.xxxx.fssso.db.dao.DBDao;
+import com.eco.plugin.xxxx.fssso.utils.FRUtils;
+import com.fr.db.fun.impl.AbstractDBAccessProvider;
+import com.fr.plugin.transform.FunctionRecorder;
+import com.fr.record.analyzer.EnableMetrics;
+import com.fr.stable.db.accessor.DBAccessor;
+import com.fr.stable.db.action.DBAction;
+import com.fr.stable.db.dao.DAOContext;
+import com.fr.stable.db.dao.DAOProvider;
+
+import java.util.UUID;
+
+/**
+ * @author fr.open
+ * @version 10.0
+ * Created by fr.open on 2021-11-30
+ **/
+@EnableMetrics
+@FunctionRecorder
+public class DBController extends AbstractDBAccessProvider {
+
+ private static DBAccessor accessor;
+
+ public static DBAccessor getAccessor() {
+ return accessor;
+ }
+
+ @Override
+ public DAOProvider[] registerDAO() {
+ return new DAOProvider[]{
+ DBDao.DAO
+ };
+ }
+
+ @Override
+ public void onDBAvailable(DBAccessor accessor) {
+ DBController.accessor = accessor;
+ }
+ /**
+ * 新增
+ * @param bean
+ */
+ public static void add( final DBEntity bean ){
+ try{
+ accessor.runDMLAction(new DBAction() {
+ @Override
+ public Boolean run(DAOContext context) throws Exception {
+ bean.setId(UUID.randomUUID().toString());
+ context.getDAO(DBDao.class).add(bean);
+
+ return true;
+ }
+ });
+ }catch(Throwable e){
+ FRUtils.FRLogError("exception addOrUpdate:"+e.getMessage());
+ }
+ }
+
+}
diff --git a/src/main/java/com/eco/plugin/xxxx/fssso/db/dao/DBDao.java b/src/main/java/com/eco/plugin/xxxx/fssso/db/dao/DBDao.java
new file mode 100644
index 0000000..57c6894
--- /dev/null
+++ b/src/main/java/com/eco/plugin/xxxx/fssso/db/dao/DBDao.java
@@ -0,0 +1,39 @@
+package com.eco.plugin.xxxx.fssso.db.dao;
+
+import com.eco.plugin.xxxx.fssso.db.bean.DBEntity;
+import com.fr.stable.db.dao.BaseDAO;
+import com.fr.stable.db.dao.DAOProvider;
+import com.fr.stable.db.session.DAOSession;
+
+/**
+ * @author fr.open
+ * @version 10.0
+ * Created by fr.open on 2021-11-30
+ **/
+public class DBDao extends BaseDAO {
+
+ public DBDao(DAOSession session) {
+ super(session);
+ }
+
+ @Override
+ protected Class getEntityClass() {
+ return DBEntity.class;
+ }
+
+ public final static DAOProvider DAO = new DAOProvider() {
+ @Override
+ public Class getEntityClass() {
+ return DBEntity.class;
+ }
+
+ @Override
+ public Class extends BaseDAO> getDAOClass() {
+ return DBDao.class;
+ }
+ };
+
+ public void add(DBEntity entity) throws Exception {
+ getSession().persist(entity);
+ }
+}
diff --git a/src/main/java/com/eco/plugin/xxxx/fssso/dsdd/db/DBAccessProvider.java b/src/main/java/com/eco/plugin/xxxx/fssso/dsdd/db/DBAccessProvider.java
new file mode 100644
index 0000000..12fb954
--- /dev/null
+++ b/src/main/java/com/eco/plugin/xxxx/fssso/dsdd/db/DBAccessProvider.java
@@ -0,0 +1,38 @@
+package com.eco.plugin.xxxx.fssso.dsdd.db;
+
+import com.eco.plugin.xxxx.fssso.dsdd.dsdd.TsEntity;
+import com.fr.decision.plugin.db.AbstractDecisionDBAccessProvider;
+import com.fr.stable.db.accessor.DBAccessor;
+import com.fr.stable.db.dao.BaseDAO;
+import com.fr.stable.db.dao.DAOProvider;
+
+public class DBAccessProvider extends AbstractDecisionDBAccessProvider {
+ private static DBAccessor dbAccessor = null;
+
+ public static DBAccessor getDbAccessor(){
+ return dbAccessor;
+ }
+
+
+ @Override
+ public DAOProvider[] registerDAO() {
+ return new DAOProvider[]{
+ new DAOProvider() {
+ @Override
+ public Class getEntityClass() {
+ return TsEntity.class;
+ }
+
+ @Override
+ public Class extends BaseDAO> getDAOClass() {
+ return Dao.class;
+ }
+ }
+ };
+ }
+
+ @Override
+ public void onDBAvailable(DBAccessor dbAccessor) {
+ this.dbAccessor = dbAccessor;
+ }
+}
diff --git a/src/main/java/com/eco/plugin/xxxx/fssso/dsdd/db/Dao.java b/src/main/java/com/eco/plugin/xxxx/fssso/dsdd/db/Dao.java
new file mode 100644
index 0000000..ddfc111
--- /dev/null
+++ b/src/main/java/com/eco/plugin/xxxx/fssso/dsdd/db/Dao.java
@@ -0,0 +1,14 @@
+package com.eco.plugin.xxxx.fssso.dsdd.db;
+
+import com.eco.plugin.xxxx.fssso.dsdd.dsdd.TsEntity;
+import com.fr.stable.db.dao.BaseDAO;
+import com.fr.stable.db.session.DAOSession;
+/**
+ * Created by fr.open on 2021-12-06.
+ */
+public class Dao extends BaseDAO {
+
+ public Dao(DAOSession daoSession) {
+ super(daoSession);
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/eco/plugin/xxxx/fssso/dsdd/dsdd/DSDDMsgFormula.java b/src/main/java/com/eco/plugin/xxxx/fssso/dsdd/dsdd/DSDDMsgFormula.java
new file mode 100644
index 0000000..912bd0d
--- /dev/null
+++ b/src/main/java/com/eco/plugin/xxxx/fssso/dsdd/dsdd/DSDDMsgFormula.java
@@ -0,0 +1,23 @@
+package com.eco.plugin.xxxx.fssso.dsdd.dsdd;
+
+import com.fr.main.workbook.ResultWorkBook;
+import com.fr.schedule.base.provider.impl.AbstractOutputFormulaProvider;
+import com.fr.schedule.extension.report.util.ScheduleParameterUtils;
+
+import java.util.List;
+import java.util.Map;
+
+public class DSDDMsgFormula extends AbstractOutputFormulaProvider {
+ public DSDDMsgFormula() {
+ }
+
+ public void dealWithFormulaParam(TsBean var1, ResultWorkBook var2, List