xujiaheng пре 3 година
родитељ
комит
7787ee7cf8

+ 10 - 2
src/main/java/com/persagy/apm/alarmservice/alarmcondition/controller/AlarmConditionController.java

@@ -5,7 +5,6 @@ import com.persagy.apm.alarmservice.alarmcondition.service.IAlarmConditionServic
 import org.springframework.beans.factory.annotation.Autowired;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
-import io.swagger.annotations.ApiParam;
 import com.persagy.apm.alarmservice.alarmcondition.model.*;
 import com.persagy.apm.alarmservice.alarmcondition.model.vo.*;
 import com.persagy.apm.alarmservice.alarmcondition.model.dto.*;
@@ -13,6 +12,8 @@ import com.persagy.apm.common.response.*;
 import com.persagy.apm.common.utils.ResultHelper;
 import org.springframework.validation.annotation.Validated;
 import org.springframework.web.bind.annotation.*;
+import springfox.documentation.annotations.ApiIgnore;
+
 import javax.validation.Valid;
 import java.util.List;
 
@@ -21,7 +22,7 @@ import java.util.List;
  * @author lixing
  * @version V1.0 2021-09-08 22:30:38
  */
-@Api(tags = "报警条件") 
+@Api(tags = "报警条件")
 @Validated
 @RestController
 @RequestMapping("alarmConditions")
@@ -88,5 +89,12 @@ public class AlarmConditionController {
     //    });
     //    return ResultHelper.multi(pagedResultList);
     //}
+
+    @ApiOperation(value = "报警条件合法性校验")
+    @PostMapping("/validate")
+    public CommonResult<Boolean> validate(
+            @Valid @RequestBody ValidateAlarmConditionDTO validateAlarmConditionDTO) {
+        return ResultHelper.success();
+    }
 }
 

+ 2 - 2
src/main/java/com/persagy/apm/alarmservice/alarmcondition/model/AlarmCondition.java

@@ -24,10 +24,10 @@ public class AlarmCondition extends AuditableEntity<AlarmCondition> implements S
     private Object infoCodes;
     
     @ApiModelProperty("前端展示")
-    private Object frontend;
+    private String frontend;
     
     @ApiModelProperty("后端使用")
-    private Object backend;
+    private String backend;
     
     @ApiModelProperty("触发时长")
     private Integer triggerUphold;

+ 7 - 8
src/main/java/com/persagy/apm/alarmservice/alarmcondition/model/dto/AddAlarmConditionDTO.java

@@ -1,10 +1,13 @@
 package com.persagy.apm.alarmservice.alarmcondition.model.dto;
 
+import com.persagy.apm.alarmservice.calculatemethod.model.dto.CalculateMethodDTO;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 import javax.validation.constraints.NotNull;
 import lombok.Data;
 import java.util.Date;
+import java.util.List;
+import java.util.Map;
 
 /**
  * @author lixing
@@ -15,15 +18,11 @@ import java.util.Date;
 public class AddAlarmConditionDTO {
     @ApiModelProperty(value = "包含的参数", required = true)
     @NotNull(message = "包含的参数不能为空") // todo 更新校验规则
-    private Object infoCodes;
+    private Map<String,String> infoCodes;
     
-    @ApiModelProperty(value = "前端展示", required = true)
-    @NotNull(message = "前端展示不能为空") // todo 更新校验规则
-    private Object frontend;
-    
-    @ApiModelProperty(value = "后端使用", required = true)
-    @NotNull(message = "后端使用不能为空") // todo 更新校验规则
-    private Object backend;
+    @ApiModelProperty(value = "报警触发规则", required = true)
+    @NotNull(message = "报警触发规则不能为空") // todo 更新校验规则
+    private List<List<CalculateMethodDTO>> frontend;
     
     @ApiModelProperty(value = "触发时长", required = true)
     @NotNull(message = "触发时长不能为空") // todo 更新校验规则

+ 25 - 0
src/main/java/com/persagy/apm/alarmservice/alarmcondition/model/dto/ValidateAlarmConditionDTO.java

@@ -0,0 +1,25 @@
+package com.persagy.apm.alarmservice.alarmcondition.model.dto;
+
+import com.persagy.apm.alarmservice.calculatemethod.model.dto.CalculateMethodDTO;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import javax.validation.constraints.NotNull;
+
+/**
+ * @author lixing
+ * @version V1.0 2021-09-08 22:30:38
+ */
+@Data
+@ApiModel(value = "报警条件合法性校验入参")
+public class ValidateAlarmConditionDTO {
+    @ApiModelProperty(value = "包含的参数", required = true)
+    @NotNull(message = "包含的参数不能为空") // todo 更新校验规则
+    private Object infoCodes;
+    
+    @ApiModelProperty(value = "报警条件", required = true)
+    @NotNull(message = "报警条件不能为空") // todo 更新校验规则
+    private CalculateMethodDTO frontend;
+    
+}

+ 35 - 1
src/main/java/com/persagy/apm/alarmservice/alarmcondition/service/impl/AlarmConditionServiceImpl.java

@@ -1,5 +1,6 @@
 package com.persagy.apm.alarmservice.alarmcondition.service.impl;
 
+import com.alibaba.fastjson.JSON;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
@@ -13,14 +14,18 @@ import com.persagy.apm.alarmservice.alarmcondition.model.dto.PageQueryAlarmCondi
 import com.persagy.apm.alarmservice.alarmcondition.model.dto.QueryAlarmConditionDTO;
 import com.persagy.apm.alarmservice.alarmcondition.model.dto.UpdateAlarmConditionDTO;
 import com.persagy.apm.alarmservice.alarmcondition.service.IAlarmConditionService;
+import com.persagy.apm.alarmservice.calculatemethod.model.dto.CalculateMethodDTO;
+import com.persagy.apm.common.configuration.DataUtils;
 import com.persagy.apm.common.constant.enums.ValidEnum;
 import com.persagy.apm.common.context.poems.PoemsContext;
 import com.persagy.apm.common.model.dto.Sort;
 import org.apache.commons.lang.StringUtils;
+import org.json.JSONArray;
 import org.springframework.stereotype.Service;
 import org.springframework.util.CollectionUtils;
 
 import java.util.List;
+import java.util.Map;
 
 /**
  * 报警条件(AlarmCondition) service层
@@ -41,12 +46,40 @@ public class AlarmConditionServiceImpl extends ServiceImpl<AlarmConditionMapper,
     @Override
     public String createAlarmCondition(AddAlarmConditionDTO addAlarmConditionDTO) {
         AlarmCondition alarmCondition = ConvertAlarmConditionTool.INSTANCE.convertAddDto2Entity(addAlarmConditionDTO);
+        List<List<CalculateMethodDTO>> frontend = addAlarmConditionDTO.getFrontend();
+        Map<String, String> infoCodes = addAlarmConditionDTO.getInfoCodes();
+        String frontJson = JSON.toJSONString(frontend);
+        alarmCondition.setFrontend(frontJson);
+        //将前端公式转换成后台公式
+        String backend = frontend2Backend(frontend,infoCodes);
+        alarmCondition.setBackend(backend);
         // 设置默认值
         setDefaultValue(alarmCondition);
         save(alarmCondition);
         return alarmCondition.getId();
     }
-    
+
+    private String frontend2Backend(List<List<CalculateMethodDTO>> frontend, Map<String, String> infoCodes) {
+
+        for (List<CalculateMethodDTO> calculateMethodDTOS : frontend) {
+            StringBuffer sb = new StringBuffer();
+
+            for (CalculateMethodDTO calculateMethodDTO : calculateMethodDTOS) {
+                StringBuffer calculateString = new StringBuffer();
+                calculateString.append("(")
+                        .append(calculateMethodDTO.getMonitorIndicatorId())
+                .append(calculateMethodDTO.getOperator())
+                .append(calculateMethodDTO.getFormula()).append(") &&");
+                sb.append(calculateString);
+            }
+
+        }
+//        for (Map.Entry<String, String> entry : infoCodes.entrySet()) {
+//            calculateString.toString().replace(entry.getKey(),entry.getValue());
+//        }
+        return null;
+    }
+
     /**
      * 如果某些字段没有赋值,使用默认的值
      *
@@ -56,6 +89,7 @@ public class AlarmConditionServiceImpl extends ServiceImpl<AlarmConditionMapper,
      */
     private void setDefaultValue(AlarmCondition alarmCondition) {
         alarmCondition.setCreator(PoemsContext.getContext().getUserId());
+        alarmCondition.setId(DataUtils.getUUID());
         // todo 其他默认的属性
         
     }

+ 32 - 0
src/main/java/com/persagy/apm/alarmservice/calculatemethod/model/dto/CalculateMethodDTO.java

@@ -0,0 +1,32 @@
+package com.persagy.apm.alarmservice.calculatemethod.model.dto;
+
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import javax.validation.constraints.NotNull;
+
+/**
+ * @author lixing
+ * @version V1.0 2021-09-08 22:43:58
+ */
+@Data
+@ApiModel(value = "创建计算方式入参")
+public class CalculateMethodDTO {
+    @ApiModelProperty(value = "计算方式名称", required = true)
+    @NotNull(message = "操作符") // todo 更新校验规则
+    private String operator;
+    
+    @ApiModelProperty(value = "公式", required = true)
+    @NotNull(message = "公式不能为空") // todo 更新校验规则
+    private String formula;
+    
+    @ApiModelProperty(value = "监测指标id", required = true)
+    @NotNull(message = "监测指标id不能为空") // todo 更新校验规则
+    private String monitorIndicatorId;
+    
+    @ApiModelProperty(value = "是否是指标默认计算方式", required = true)
+    @NotNull(message = "是否是指标默认计算方式不能为空") // todo 更新校验规则
+    private Integer isDefault;
+    
+}

+ 2 - 0
src/main/java/com/persagy/apm/alarmservice/group/alarmrule/controller/GroupAlarmRuleController.java

@@ -88,5 +88,7 @@ public class GroupAlarmRuleController {
     //    });
     //    return ResultHelper.multi(pagedResultList);
     //}
+
+
 }
 

+ 5 - 4
src/main/java/com/persagy/apm/alarmservice/group/alarmrule/model/dto/AddGroupAlarmRuleDTO.java

@@ -1,5 +1,6 @@
 package com.persagy.apm.alarmservice.group.alarmrule.model.dto;
 
+import com.persagy.apm.alarmservice.alarmcondition.model.dto.AddAlarmConditionDTO;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 import javax.validation.constraints.NotNull;
@@ -20,9 +21,9 @@ public class AddGroupAlarmRuleDTO {
     @ApiModelProperty(value = "报警条目编码", required = true)
     @NotNull(message = "报警条目编码不能为空") // todo 更新校验规则
     private String alarmItemCode;
-    
-    @ApiModelProperty(value = "报警条件id", required = true)
-    @NotNull(message = "报警条件id不能为空") // todo 更新校验规则
-    private String alarmConditionId;
+
+    @ApiModelProperty(value = "报警规则", required = true)
+    @NotNull(message = "报警规则不能为空") // todo 更新校验规则
+    private AddAlarmConditionDTO alarmCondition;
     
 }

+ 3 - 2
src/main/java/com/persagy/apm/alarmservice/group/alarmrule/model/vo/GroupAlarmRuleListItemVO.java

@@ -1,5 +1,6 @@
 package com.persagy.apm.alarmservice.group.alarmrule.model.vo;
 
+import com.persagy.apm.alarmservice.alarmcondition.model.vo.AlarmConditionListItemVO;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
@@ -23,8 +24,8 @@ public class GroupAlarmRuleListItemVO {
     @ApiModelProperty("报警条目编码")
     private String alarmItemCode;
     
-    @ApiModelProperty("报警条件id")
-    private String alarmConditionId;
+    @ApiModelProperty("报警条件")
+    private AlarmConditionListItemVO alarmConditionList;
     
     @ApiModelProperty("创建人")
     private String creator;

+ 10 - 1
src/main/java/com/persagy/apm/alarmservice/group/alarmrule/service/impl/GroupAlarmRuleServiceImpl.java

@@ -1,9 +1,13 @@
 package com.persagy.apm.alarmservice.group.alarmrule.service.impl;
 
+import com.persagy.apm.alarmservice.alarmcondition.model.dto.AddAlarmConditionDTO;
+import com.persagy.apm.alarmservice.alarmcondition.service.IAlarmConditionService;
+import com.persagy.apm.common.configuration.DataUtils;
 import com.persagy.apm.common.context.AppContext;
 import com.persagy.apm.alarmservice.group.alarmrule.dao.GroupAlarmRuleMapper;
 import com.persagy.apm.alarmservice.group.alarmrule.service.IGroupAlarmRuleService;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import org.apache.commons.lang.StringUtils;
 import com.persagy.apm.common.constant.enums.ValidEnum;
@@ -26,7 +30,8 @@ import org.springframework.util.CollectionUtils;
 @Service
 public class GroupAlarmRuleServiceImpl extends ServiceImpl<GroupAlarmRuleMapper, GroupAlarmRule> 
     implements IGroupAlarmRuleService {
-    
+    @Autowired
+    private IAlarmConditionService alarmConditionService;
     /**
     * 创建集团报警规则
     * @return 集团报警规则主键
@@ -36,7 +41,10 @@ public class GroupAlarmRuleServiceImpl extends ServiceImpl<GroupAlarmRuleMapper,
     @Override
     public String createGroupAlarmRule(AddGroupAlarmRuleDTO addGroupAlarmRuleDTO) {
         GroupAlarmRule groupAlarmRule = ConvertGroupAlarmRuleTool.INSTANCE.convertAddDto2Entity(addGroupAlarmRuleDTO);
+        AddAlarmConditionDTO alarmCondition = addGroupAlarmRuleDTO.getAlarmCondition();
+        String alarmConditionId = alarmConditionService.createAlarmCondition(alarmCondition);
         // 设置默认值
+        groupAlarmRule.setAlarmConditionId(alarmConditionId);
         setDefaultValue(groupAlarmRule);
         save(groupAlarmRule);
         return groupAlarmRule.getId();
@@ -51,6 +59,7 @@ public class GroupAlarmRuleServiceImpl extends ServiceImpl<GroupAlarmRuleMapper,
      */
     private void setDefaultValue(GroupAlarmRule groupAlarmRule) {
         groupAlarmRule.setCreator(AppContext.getContext().getAccountId());
+        groupAlarmRule.setId(DataUtils.getUUID());
         // todo 其他默认的属性
         
     }

+ 324 - 0
src/main/java/com/persagy/apm/common/configuration/DataUtils.java

@@ -0,0 +1,324 @@
+package com.persagy.apm.common.configuration;
+
+import com.alibaba.fastjson.JSONObject;
+import org.apache.commons.lang.StringUtils;
+import org.springframework.util.CollectionUtils;
+
+import java.lang.reflect.Field;
+import java.lang.reflect.Modifier;
+import java.math.BigDecimal;
+import java.text.DecimalFormat;
+import java.util.*;
+
+/**
+ * 数值、集合处理工具类
+ *
+ * @author feng
+ */
+public class DataUtils {
+
+    /**
+     * 对象转Double类型
+     *
+     * @param object
+     * @return
+     */
+    public static Double parseDouble(Object object) {
+        if (object == null) {
+            return null;
+        }
+        if (object instanceof String) {
+            if (StringUtils.isBlank((String) object)) {
+                return null;
+            }
+            return Double.valueOf(object.toString());
+        }
+        if (object instanceof Integer) {
+            return ((Integer) object).doubleValue();
+        }
+        if (object instanceof Long) {
+            return ((Long) object).doubleValue();
+        }
+        if (object instanceof Double) {
+            return (Double) object;
+        }
+        if (object instanceof BigDecimal){
+            return ((BigDecimal) object).doubleValue();
+        }
+        return (Double) object;
+    }
+
+    public static String parseString(Object object) {
+        if (object == null) {
+            return "";
+        }
+        if(object instanceof Double){
+            Long objectLong = ((Double) object).longValue();
+            if(objectLong.doubleValue()== (Double) object){
+                return objectLong.toString();
+            }
+            BigDecimal bigDecimal = BigDecimal.valueOf((double) object);
+            return bigDecimal.toString();
+        }
+        return object.toString();
+    }
+
+    /**
+     * 设置小数精度
+     *
+     * @param obj
+     * @param count 精确的小数位数
+     * @return
+     */
+    public static Double setDecimalScale(Double obj, int count) {
+        if (obj == null) {
+            return null;
+        }
+        BigDecimal bd = new BigDecimal(obj);
+        return bd.setScale(count, BigDecimal.ROUND_HALF_UP).doubleValue();
+    }
+
+    public static String getUUID(){
+        return UUID.randomUUID().toString().replace("-", "");
+    }
+
+    /**
+     * 将Double类型的数字向下取整
+     *
+     * @param num
+     * @return
+     */
+    public static String getInt(Object num) {
+        if (num == null) {
+            return null;
+        }
+        try {
+            Double dob = Double.valueOf(num + "");
+            DecimalFormat df = new DecimalFormat("#.#");
+            return df.format(dob);
+        } catch (Exception e) {
+            return num + "";
+        }
+    }
+
+    /**
+     * BigDecimal精确计算
+     *
+     * @param dividend
+     * @param divisor
+     * @param decimalScale 小数点精确范围
+     * @return
+     * @throws Exception
+     */
+    public static <T extends Number> Double divide(T dividend, T divisor, Integer decimalScale) throws Exception {
+        if (dividend == null || divisor == null) {
+            return null;
+        }
+        if (divisor.doubleValue() == 0) {
+            return null;
+        }
+        if (decimalScale == null) {
+            decimalScale = DECIMAL_SCALE;
+        }
+        BigDecimal dividendDecimal = new BigDecimal(dividend.toString());
+        BigDecimal divisorDecimal = new BigDecimal(divisor.toString());
+        return dividendDecimal.divide(divisorDecimal, decimalScale, BigDecimal.ROUND_HALF_UP).doubleValue();
+    }
+
+    private static final int DECIMAL_SCALE = 12;
+    public static <T extends Number> Double divide(T dividend, T divisor) throws Exception {
+        return divide(dividend,divisor,DECIMAL_SCALE);
+    }
+
+    public static Double subtract(Double minuend, Double subtrahend) {
+        if (minuend == null && subtrahend == null) {
+            return null;
+        }
+        if (minuend == null) {
+            return -subtrahend;
+        }
+        if (subtrahend == null) {
+            return minuend;
+        }
+        return minuend - subtrahend;
+    }
+
+    public static Double plus(Double data1, Double data2) {
+        if (data1 == null && data2 == null) {
+            return null;
+        }
+        if (data1 == null) {
+            return data2;
+        }
+        if (data2 == null) {
+            return data1;
+        }
+        return data1 + data2;
+    }
+
+    public static Double plus(Double... dataList) {
+        Double sum = null;
+        for (Double data : dataList) {
+            sum = plus(sum, data);
+        }
+        return sum;
+    }
+
+    public static Integer plus(Integer... dataList) {
+        Integer sum = null;
+        for (Integer data : dataList) {
+            sum = plus(sum, data);
+        }
+        return sum;
+    }
+    public static Integer plus(Integer data1, Integer data2) {
+        if (data1 == null && data2 == null) {
+            return null;
+        }
+        if (data1 == null) {
+            return data2;
+        }
+        if (data2 == null) {
+            return data1;
+        }
+        return data1 + data2;
+    }
+
+    public static Integer getInt(Double data) {
+        if (data == null) {
+            return null;
+        }
+        return (int) (data + 0.5);
+    }
+
+    public static Double formatDataNumber(Double energyData) {
+        if (energyData == null) {
+            return null;
+        }
+        if (energyData < 1) {
+            return DataUtils.setDecimalScale(energyData, 3);
+        } else if (energyData < 1000) {
+            return DataUtils.setDecimalScale(energyData, 1);
+        } else {
+            return Math.round(energyData) * 1.0;
+        }
+    }
+
+    @SuppressWarnings({ "unchecked", "rawtypes" })
+	public static void sortList(List srcList, String sortField, boolean isAsc) throws Exception{
+        if(CollectionUtils.isEmpty(srcList)){
+            return;
+        }
+        Collections.sort(srcList, (o1, o2) -> {
+            JSONObject object1 = JSONObject.parseObject(JSONObject.toJSONString(o1));
+            JSONObject object2 = JSONObject.parseObject(JSONObject.toJSONString(o2));
+            Object name1 = object1.get(sortField);
+            Object name2 = object2.get(sortField);
+            int coefficient;
+            if (isAsc) {
+                coefficient = 1;
+            } else {
+                coefficient = -1;
+            }
+            if (name1 != null && name2 != null) {
+                if (name1 instanceof Double) {
+                    return ((Double) name1).compareTo((Double) name2) * coefficient;
+                } else if (name1 instanceof Integer) {
+                    return ((Integer) name1).compareTo((Integer) name2) * coefficient;
+                } else if (name1 instanceof Long) {
+                    return ((Long) name1).compareTo((Long) name2) * coefficient;
+                } else if (name1 instanceof BigDecimal) {
+                    return ((BigDecimal) name1).compareTo((BigDecimal) name2) * coefficient;
+                } else if(name1 instanceof Date){
+                    return ((Date) name1).compareTo((Date) name2) * coefficient;
+                } else {
+                    return ((String) name1).compareTo(((String) name2)) * coefficient;
+                }
+            } else if (name1 != null) {
+                return coefficient;
+            } else if (name2 != null) {
+                return -coefficient;
+            } else {
+                return 0;
+            }
+
+        });
+    }
+
+
+    public static void sortList(List<Object> energyList) {
+        Collections.sort(energyList, (o1, o2) -> {
+            if (o1 == null && o2 == null) {
+                return 0;
+            } else if (o1 == null) {
+                return -1;
+            } else if (o2 == null) {
+                return 1;
+            } else {
+                if (o1 instanceof Double) {
+                    return ((Double) o1).compareTo((Double) o2);
+                } else if (o1 instanceof Integer) {
+                    return ((Integer) o1).compareTo((Integer) o2);
+                } else if (o1 instanceof Long) {
+                    return ((Long) o1).compareTo((Long) o2);
+                } else if (o1 instanceof BigDecimal) {
+                    return ((BigDecimal) o1).compareTo((BigDecimal) o2);
+                } else if (o1 instanceof Date) {
+                    return ((Date) o1).compareTo((Date) o2);
+                } else {
+                    return ((String) o1).compareTo(((String) o2));
+                }
+            }
+        });
+    }
+
+    public static List<String> getPagingObjectList(List<String> allObjectList, Integer pageNum, Integer pageSize) {
+        if (CollectionUtils.isEmpty(allObjectList)) {
+            return new ArrayList<>();
+        }
+
+        int skipCount = (pageNum - 1) * pageSize;
+        int totalCount = allObjectList.size();
+        if (skipCount >= totalCount) {
+            return new ArrayList<>();
+        }
+        List<String> resultList = new ArrayList<>();
+        for (int i = 0; i < pageSize; i++) {
+            int index = skipCount + i;
+            if (index >= totalCount) {
+                break;
+            }
+            resultList.add(allObjectList.get(index));
+        }
+        return resultList;
+    }
+
+    /**
+     * description 筛选originMapList中包含keyWord的对象
+     * @param originMapList
+     * @param keyWord
+     * @return java.util.List<java.util.Map<java.lang.String,java.lang.Object>>
+     * @author feng
+     * @since 19:47 2020/6/4
+     * @version 1.0
+     */
+    public static List<Map<String, Object>> queryByKeyWord(List<Map<String, Object>> originMapList, String keyWord) {
+        if (StringUtils.isBlank(keyWord)) {
+            return originMapList;
+        }
+        if (CollectionUtils.isEmpty(originMapList)) {
+            return new ArrayList<>();
+        }
+        List<Map<String, Object>> resultMapList = new ArrayList<>();
+        for (Map<String, Object> originMap : originMapList) {
+            for (String key : originMap.keySet()) {
+                Object data = originMap.get(key);
+                if (data != null && data.toString().contains(keyWord)) {
+                    resultMapList.add(originMap);
+                    break;
+                }
+            }
+        }
+        return resultMapList;
+    }
+}