mirror of
https://gitee.com/dromara/liteFlow.git
synced 2026-06-10 19:26:54 +08:00
bug #I9N5K8 在自定义组件后,通过getCmpData 获取data的实体对象,data字段与实体类不匹配是会抛异常
This commit is contained in:
@@ -3,6 +3,7 @@ package com.yomahub.liteflow.util;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.fasterxml.jackson.core.JsonProcessingException;
|
||||
import com.fasterxml.jackson.databind.DeserializationFeature;
|
||||
import com.fasterxml.jackson.databind.JsonNode;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import com.yomahub.liteflow.exception.JsonProcessException;
|
||||
@@ -27,6 +28,7 @@ public class JsonUtil {
|
||||
|
||||
static {
|
||||
objectMapper.setTimeZone(TimeZone.getDefault());
|
||||
objectMapper.disable(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES);
|
||||
}
|
||||
|
||||
public static String toJsonString(Object object) {
|
||||
@@ -71,5 +73,4 @@ public class JsonUtil {
|
||||
throw new JsonProcessException(errMsg);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user