Package org.joget.apps.datalist.model

Examples of org.joget.apps.datalist.model.DataListFilterType


                }
                if (filter.has(PROPERTY_OPERATOR)) {
                    dataListFilter.setOperator(filter.getString(PROPERTY_OPERATOR));
                }
                if (filter.has(PROPERTY_FILTER_TYPE)) {
                    DataListFilterType type = parseFilterTypeFromJsonObject(filter);
                    dataListFilter.setType(type);
                }
               
                property.add(dataListFilter);
            }
View Full Code Here


    public static DataListFilterType parseFilterTypeFromJsonObject(JSONObject obj) throws JSONException, InstantiationException, IllegalAccessException {
        if (!obj.isNull(PROPERTY_FILTER_TYPE)) {
            JSONObject filterTypeObj = obj.getJSONObject(PROPERTY_FILTER_TYPE);
            if (filterTypeObj.has(PROPERTY_CLASS_NAME)) {
                String className = filterTypeObj.getString(PROPERTY_CLASS_NAME);
                DataListFilterType dataListFilterType = (DataListFilterType) loadPlugin(className);
                if (dataListFilterType != null) {
                    dataListFilterType.setProperties(PropertyUtil.getPropertiesValueFromJson(filterTypeObj.getJSONObject(PROPERTY_PROPERTIES).toString()));
                    return dataListFilterType;                   
                }
            }
        }
        return null;
View Full Code Here

        if (obj.get("operator") != null) {
            filter.setOperator(obj.get("operator").toString());
        }
        if (obj.get("type") != null) {
            Map typeMap = (Map) obj.get("type");
            DataListFilterType type = (DataListFilterType) pluginManager.getPlugin(typeMap.get("className").toString());
            if (type != null) {
                if (!"{}".equals(typeMap.get("properties"))) {
                    type.setProperties((Map) typeMap.get("properties"));
                }
                filter.setType(type);
            }
        }
View Full Code Here

TOP

Related Classes of org.joget.apps.datalist.model.DataListFilterType

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.