Browse Source

rwd: 支持对数字类型信息点未赋值时的查询

yaoll 3 years ago
parent
commit
4da6dc7d05

+ 2 - 0
dmp-rwd/src/main/java/com/persagy/dmp/rwd/service/ObjectInstanceQueryService.java

@@ -110,8 +110,10 @@ public class ObjectInstanceQueryService extends BaseService {
 			if (funcidDataType == FuncidDataType.STRING) {
 				list.addAll(CriteriaUtils.parse(Expressions.stringTemplate(exp, qt.infos), value));
 			} else if (funcidDataType == FuncidDataType.INTEGER) {
+				exp = "ifnull(json_extract({0}, '$." + infoCode + "'), -9999)";
 				list.addAll(CriteriaUtils.parse(Expressions.numberTemplate(Long.class, exp, qt.infos), value));
 			} else if (funcidDataType == FuncidDataType.DOUBLE) {
+				exp = "ifnull(json_extract({0}, '$." + infoCode + "'), -9999.99)";
 				list.addAll(CriteriaUtils.parse(Expressions.numberTemplate(Double.class, exp, qt.infos), value));
 			} else if (funcidDataType == FuncidDataType.BOOLEAN) {
 				// TODO