Joget DX 8 Stable Released
The stable release for Joget DX 8 is now available, with a focus on UX and Governance.
...
...
DatalistBuilder.getColumnOptions(properties)
Can be used by plugins related to Datalist Builder. It return all available columns based on binder configuration.
可以使用与Datalist Builder相关的插件。它将根据绑定器配置返回所有可用的列。
例:
Example:
Code Block | ||
---|---|---|
| ||
buttons : [{ name : 'testmail', label : 'Send Test Email', ajax_url : '[CONTEXT_PATH]/web/json/app[APP_PATH]/plugin/org.joget.apps.app.lib.EmailTool/service?action=testmail', fields : ['host', 'port', 'security', 'username', 'password'], addition_fields : [ { name : 'from', label : 'From', type : 'textfield', required : 'True' }, { name : 'toSpecific', label : 'To', type : 'textfield', required : 'True' } ] }] |
...
...
Code Block | ||
---|---|---|
| ||
String value = getPropertyString("property_name"); |
...
Code Block | ||
---|---|---|
| ||
String[] values = getPropertyString("property_name").split(";"); |
...
Code Block | ||
---|---|---|
| ||
Object columns = getProperty("property_name"); if (columns != null) { for (Object colObj : (Object[]) columns) { Map col = (Map) colObj; String col1_value = (String) opt.get("col1_key"); String col2_value = (String) opt.get("col2_key"); } } |
...
...
Code Block | ||
---|---|---|
| ||
import org.joget.plugin.base.PluginManager; import org.joget.apps.app.service.AppUtil; import org.joget.plugin.base.ExtDefaultPlugin; Object element = getProperty("property_name"); if (element != null && element instanceof Map) { Map elementMap = (Map) element; String className = (String) elementMap.get("className"); Map<String, Object> properties = (Map<String, Object>) elementMap.get("properties"); //convert it to plugin PluginManager pm = (PluginManager) AppUtil.getApplicationContext().getBean("pluginManager"); ExtDefaultPlugin plugin = (ExtDefaultPlugin) pm.getPlugin(className); if (plugin != null) { plugin.setProperties(properties); } } |