Browse Source

设计器使用可以不限制试用期

master
richie 9 years ago
parent
commit
f1b6893251
  1. 4
      plugin.xml
  2. 3
      src/com/fr/plugin/widget/ztree/ZTreeLocaleFinder.java
  3. 9
      src/com/fr/plugin/widget/ztree/core/ZTree.java
  4. 9
      src/com/fr/plugin/widget/ztree/core/ZTreeConstants.java
  5. 1
      src/com/fr/plugin/widget/ztree/core/ZTreeMarkInForm.java

4
plugin.xml

@ -2,7 +2,7 @@
<id>com.fr.plugin.widget.ztree</id>
<name><![CDATA[急速下拉树控件]]></name>
<active>yes</active>
<version>7.0</version>
<version>7.1</version>
<env-version>8.0</env-version>
<jartime>2016-03-20</jartime>
<vendor>solution.richie</vendor>
@ -18,6 +18,8 @@
<p>[2015-12-11]增加弹出层高度设置属性;弹出层宽度跟随控件宽度</p>
<p>[2016-01-15]修正弹出层会被图表遮住无法选择的问题</p>
<p>[2016-03-20]修复了超级大bug</p>
<p>[2016-04-11]修复了无法试用的bug</p>
<p>[2016-04-11]在设计器里面可以无限试用</p>
]]></change-notes>
<extra-core>
<LocaleFinder class="com.fr.plugin.widget.ztree.ZTreeLocaleFinder"/>

3
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

9
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);

9
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";
}

1
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

Loading…
Cancel
Save