From e0fce3c28b025808fbc7dccff5ac3eca497ef9b7 Mon Sep 17 00:00:00 2001 From: dengzedong <dengzedong@email> Date: 星期一, 31 三月 2025 22:30:51 +0800 Subject: [PATCH] IndTimeLimitEnum ALL --- iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/ind/collection/utils/IndSqlUtils.java | 3 +++ iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/common/enums/IndTimeLimitEnum.java | 1 + iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/ind/value/service/impl/IndItemValueServiceImpl.java | 1 - 3 files changed, 4 insertions(+), 1 deletions(-) diff --git a/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/common/enums/IndTimeLimitEnum.java b/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/common/enums/IndTimeLimitEnum.java index f379698..dc5b09a 100644 --- a/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/common/enums/IndTimeLimitEnum.java +++ b/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/common/enums/IndTimeLimitEnum.java @@ -23,6 +23,7 @@ LAST_YEAR("LAST_YEAR", "去年"), THIS_YEAR("THIS_YEAR_MONTH", "今年"), LAST_HOUR_24("LAST_HOUR_24", "最近24小时"), + ALL("ALL", "全部"), CUSTOM("CUSTOM", "自定义"); private String code; diff --git a/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/ind/collection/utils/IndSqlUtils.java b/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/ind/collection/utils/IndSqlUtils.java index 127c42e..96a9661 100644 --- a/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/ind/collection/utils/IndSqlUtils.java +++ b/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/ind/collection/utils/IndSqlUtils.java @@ -231,6 +231,9 @@ whereSql.append(DateUtils.format(indItem.getTimeStart(), PATTERN_MON)); whereSql.append("'"); break; + case ALL: + whereSql.append("1 = 1"); + break; default: break; } diff --git a/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/ind/value/service/impl/IndItemValueServiceImpl.java b/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/ind/value/service/impl/IndItemValueServiceImpl.java index 2453ea2..4ab275a 100644 --- a/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/ind/value/service/impl/IndItemValueServiceImpl.java +++ b/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/ind/value/service/impl/IndItemValueServiceImpl.java @@ -72,7 +72,6 @@ SQLFilter.sqlInject2(dto.getViewSql()); SQLFilter.sqlInject2(dto.getWhereSql()); SQLFilter.sqlInject2(dto.getGroupSql()); - SQLFilter.sqlInject2(dto.getGroupSql()); DataContextHolder.setDataSourceId(Long.valueOf(dto.getDataSource())); return baseDao.getSourceValue(dto); } -- Gitblit v1.9.3