diff --git a/plugin.xml b/plugin.xml
index e844b70..4ce97c3 100644
--- a/plugin.xml
+++ b/plugin.xml
@@ -2,7 +2,7 @@
com.fr.plugin.widget.ztree
yes
- 7.0
+ 7.1
8.0
2016-03-20
solution.richie
@@ -18,6 +18,8 @@
[2015-12-11]增加弹出层高度设置属性;弹出层宽度跟随控件宽度
[2016-01-15]修正弹出层会被图表遮住无法选择的问题
[2016-03-20]修复了超级大bug
+ [2016-04-11]修复了无法试用的bug
+ [2016-04-11]在设计器里面可以无限试用
]]>
diff --git a/src/com/fr/plugin/widget/ztree/ZTreeLocaleFinder.java b/src/com/fr/plugin/widget/ztree/ZTreeLocaleFinder.java
index 4591bf5..2bbdc86 100644
--- a/src/com/fr/plugin/widget/ztree/ZTreeLocaleFinder.java
+++ b/src/com/fr/plugin/widget/ztree/ZTreeLocaleFinder.java
@@ -1,10 +1,13 @@
package com.fr.plugin.widget.ztree;
+import com.fr.plugin.widget.ztree.core.ZTreeConstants;
+import com.fr.stable.fun.Authorize;
import com.fr.stable.fun.impl.AbstractLocaleFinder;
/**
* Created by richie on 15/11/17.
*/
+@Authorize(callSignKey = ZTreeConstants.PLUGIN_ID)
public class ZTreeLocaleFinder extends AbstractLocaleFinder {
@Override
diff --git a/src/com/fr/plugin/widget/ztree/core/ZTree.java b/src/com/fr/plugin/widget/ztree/core/ZTree.java
index fdaede7..eead773 100644
--- a/src/com/fr/plugin/widget/ztree/core/ZTree.java
+++ b/src/com/fr/plugin/widget/ztree/core/ZTree.java
@@ -4,6 +4,7 @@ import com.fr.form.ui.CustomWriteAbleRepeatEditor;
import com.fr.form.ui.DataControl;
import com.fr.form.ui.WidgetValue;
import com.fr.general.Inter;
+import com.fr.general.ModuleContext;
import com.fr.general.xml.GeneralXMLTools;
import com.fr.json.JSONArray;
import com.fr.json.JSONException;
@@ -121,7 +122,7 @@ public class ZTree extends CustomWriteAbleRepeatEditor implements DataControl {
return new JSONArray();
}
PluginLicense pluginLicense = PluginLicenseManager.getInstance().getPluginLicenseByID(ZTreeConstants.PLUGIN_ID);
- if (pluginLicense != null && pluginLicense.isAvailable()) {
+ if ((pluginLicense != null && pluginLicense.isAvailable()) || isDesign()) {
String pv = WebUtils.getHTTPRequestParameter(req, "pv");
int level = WebUtils.getHTTPRequestIntParameter(req, "level", ZTreeNode.ROOT_LEVEL);
String text = WebUtils.getHTTPRequestParameter(req, "text");
@@ -140,6 +141,12 @@ public class ZTree extends CustomWriteAbleRepeatEditor implements DataControl {
}
}
+
+ private boolean isDesign() {
+ return ModuleContext.isModuleStarted("com.fr.design.module.DesignerModule");
+ }
+
+
@Override
public void readXML(XMLableReader reader) {
super.readXML(reader);
diff --git a/src/com/fr/plugin/widget/ztree/core/ZTreeConstants.java b/src/com/fr/plugin/widget/ztree/core/ZTreeConstants.java
new file mode 100644
index 0000000..d498137
--- /dev/null
+++ b/src/com/fr/plugin/widget/ztree/core/ZTreeConstants.java
@@ -0,0 +1,9 @@
+package com.fr.plugin.widget.ztree.core;
+
+/**
+ * Created by richie on 16/3/21.
+ */
+public class ZTreeConstants {
+
+ public static final String PLUGIN_ID = "com.fr.plugin.widget.ztree";
+}
diff --git a/src/com/fr/plugin/widget/ztree/core/ZTreeMarkInForm.java b/src/com/fr/plugin/widget/ztree/core/ZTreeMarkInForm.java
index 0725473..252fdfb 100644
--- a/src/com/fr/plugin/widget/ztree/core/ZTreeMarkInForm.java
+++ b/src/com/fr/plugin/widget/ztree/core/ZTreeMarkInForm.java
@@ -12,7 +12,6 @@ import com.fr.stable.fun.Authorize;
/**
* Created by richie on 15/11/17.
*/
-@Authorize(callSignKey = ZTreeConstants.PLUGIN_ID)
public class ZTreeMarkInForm extends AbstractFormWidgetOptionProvider implements ParameterWidgetOptionProvider {
@Override