master #10

Closed
Roger.Chen wants to merge 3 commits from <deleted>:master into master
  1. 5
      plugin.xml
  2. 5
      src/main/java/com/fr/plugin/db/redis/RedisScriptUniversalTableDataImpl.java
  3. 5
      src/main/java/com/fr/plugin/db/redis/RedisUniversalTableDataImpl.java
  4. 6
      src/main/resources/com/fr/plugin/db/redis/web/redis.js

5
plugin.xml

@ -3,12 +3,13 @@
<id>com.fr.solution.plugin.db.redis.v10</id>
<name><![CDATA[Redis数据集]]></name>
<active>yes</active>
<version>7.4.3</version>
<version>7.5.0</version>
<env-version>10.0</env-version>
<jartime>2020-01-20</jartime>
<jartime>2021-04-12</jartime>
<vendor>richie</vendor>
<description><![CDATA[可以连接Redis数据库,支持哈希表、列表、集合以及有序集合]]></description>
<change-notes><![CDATA[
[2021-4-12]平台数据集脚本语句传输加密。<br/>
[2021-2-4]更换平台redis图片。<br/>
[2020-12-29]解决平台数据集参数公式识别错误。<br/>
[2020-11-16]修复保存数据连接后平台测试连接报错的问题。<br/>

5
src/main/java/com/fr/plugin/db/redis/RedisScriptUniversalTableDataImpl.java

@ -5,6 +5,7 @@ import com.fanruan.api.data.ConnectionKit;
import com.fanruan.api.util.StringKit;
import com.fr.data.impl.Connection;
import com.fr.decision.fun.impl.AbstractUniversalServerTableDataProvider;
import com.fr.decision.privilege.TransmissionTool;
import com.fr.json.JSONObject;
import com.fr.plugin.db.redis.bean.ParameterBean;
import com.fr.plugin.db.redis.core.RedisConstants;
@ -44,7 +45,7 @@ public class RedisScriptUniversalTableDataImpl extends AbstractUniversalServerTa
} else {
data.put(RedisConstants.ORDER, redisScriptTableData.getOrderValue().getValue());
}
data.put(RedisConstants.SCRIPT, redisScriptTableData.getScript());
data.put(RedisConstants.SCRIPT, TransmissionTool.encrypt(redisScriptTableData.getScript()));
data.put(RedisConstants.ENGINE, redisScriptTableData.getEngineType().getType());
data.put(RedisConstants.PARAMETERS, ParameterBean.createParameterBeans(redisScriptTableData.getParameters(Calculator.createCalculator())));
return data;
@ -54,7 +55,7 @@ public class RedisScriptUniversalTableDataImpl extends AbstractUniversalServerTa
public RedisScriptTableData deserialize(RedisScriptTableData oldTableData, JSONObject data) {
RedisScriptTableData newTableData = new RedisScriptTableData();
String databaseName = data.getString(RedisConstants.DATABASE);
String script = data.getString(RedisConstants.SCRIPT);
String script = TransmissionTool.decrypt(data.getString(RedisConstants.SCRIPT));
if (StringKit.isNotEmpty(databaseName) && ConnectionKit.getConnection(databaseName) != null) {
newTableData.setDatabase(ConnectionKit.createNameConnection(databaseName));
}

5
src/main/java/com/fr/plugin/db/redis/RedisUniversalTableDataImpl.java

@ -5,6 +5,7 @@ import com.fanruan.api.data.ConnectionKit;
import com.fanruan.api.util.StringKit;
import com.fr.data.impl.Connection;
import com.fr.decision.fun.impl.AbstractUniversalServerTableDataProvider;
import com.fr.decision.privilege.TransmissionTool;
import com.fr.json.JSONObject;
import com.fr.plugin.db.redis.bean.ParameterBean;
import com.fr.plugin.db.redis.core.RedisConstants;
@ -44,7 +45,7 @@ public class RedisUniversalTableDataImpl extends AbstractUniversalServerTableDat
data.put(RedisConstants.ORDER, redisTableData.getOrderValue().getValue());
}
data.put(RedisConstants.SCRIPT, redisTableData.getScript());
data.put(RedisConstants.QUERY, redisTableData.getQuery());
data.put(RedisConstants.QUERY, TransmissionTool.encrypt(redisTableData.getQuery()));
data.put(RedisConstants.PARAMETERS, ParameterBean.createParameterBeans(redisTableData.getParameters(Calculator.createCalculator())));
return data;
}
@ -54,7 +55,7 @@ public class RedisUniversalTableDataImpl extends AbstractUniversalServerTableDat
RedisTableData newTableData = new RedisTableData();
String databaseName = data.getString(RedisConstants.DATABASE);
String script = data.getString(RedisConstants.SCRIPT);
String query = data.getString(RedisConstants.QUERY);
String query = TransmissionTool.decrypt(data.getString(RedisConstants.QUERY));
if (StringKit.isNotEmpty(databaseName) && ConnectionKit.getConnection(databaseName) != null) {
newTableData.setDatabase(ConnectionKit.createNameConnection(databaseName));
}

6
src/main/resources/com/fr/plugin/db/redis/web/redis.js

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save