From 891373df7ad1e12ed3c61fc136af575aad4d323f Mon Sep 17 00:00:00 2001
From: DYL0109 <dn18191638832@163.com>
Date: 星期五, 21 三月 2025 11:38:15 +0800
Subject: [PATCH] Merge pull request #20 from Andy-Yin/zt_from_develop1.0
---
zhitan-system/src/main/resources/mapper/dailyprocessenergy/DailyProcessEnergyMapper.xml | 2 +-
zhitan-system/src/main/resources/mapper/keyequipment/DailyKeyEquipmentMapper.xml | 2 +-
zhitan-system/src/main/resources/mapper/keyequipment/MonthlyKeyEquipmentMapper.xml | 2 +-
zhitan-system/src/main/resources/mapper/dailyprocessenergy/MonthlyProcessEnergyMapper.xml | 2 +-
zhitan-system/src/main/java/com/zhitan/keyequipment/service/IYearKeyEquipmentService.java | 5 +++--
zhitan-common/src/main/java/com/zhitan/common/utils/DateTimeUtil.java | 6 ++++--
zhitan-system/src/main/resources/mapper/dailyprocessenergy/YearProcessEnergyMapper.xml | 2 +-
zhitan-system/src/main/resources/mapper/keyequipment/YearKeyEquipmentMapper.xml | 2 +-
8 files changed, 13 insertions(+), 10 deletions(-)
diff --git a/zhitan-common/src/main/java/com/zhitan/common/utils/DateTimeUtil.java b/zhitan-common/src/main/java/com/zhitan/common/utils/DateTimeUtil.java
index c359f6a..3299e26 100644
--- a/zhitan-common/src/main/java/com/zhitan/common/utils/DateTimeUtil.java
+++ b/zhitan-common/src/main/java/com/zhitan/common/utils/DateTimeUtil.java
@@ -803,10 +803,10 @@
public static List<TypeTime> getDateTimeList(String timeType, Date dataTime) {
List<TypeTime> resultList = new ArrayList<>();
-
- Date beginTime = DateUtil.beginOfDay(dataTime);
+ Date beginTime;
switch (timeType) {
case TimeTypeConst.TIME_TYPE_HOUR:
+ beginTime = DateUtil.beginOfDay(dataTime);
for (int i = 1; i <= 24; i++) {
TypeTime typeTime = new TypeTime();
typeTime.setDataTime(DateUtil.format(beginTime, COMMON_PATTERN));
@@ -818,6 +818,7 @@
}
break;
case TimeTypeConst.TIME_TYPE_DAY:
+ beginTime = DateUtil.beginOfMonth(dataTime);
for (int i = 1; i <= 31; i++) {
TypeTime typeTime = new TypeTime();
typeTime.setDataTime(DateUtil.format(beginTime, COMMON_PATTERN));
@@ -829,6 +830,7 @@
}
break;
case TimeTypeConst.TIME_TYPE_MONTH:
+ beginTime = DateUtil.beginOfYear(dataTime);
for (int i = 1; i <= 12; i++) {
TypeTime typeTime = new TypeTime();
typeTime.setDataTime(DateUtil.format(beginTime, COMMON_PATTERN));
diff --git a/zhitan-system/src/main/java/com/zhitan/keyequipment/service/IYearKeyEquipmentService.java b/zhitan-system/src/main/java/com/zhitan/keyequipment/service/IYearKeyEquipmentService.java
index 62f5f62..2ca3b8e 100644
--- a/zhitan-system/src/main/java/com/zhitan/keyequipment/service/IYearKeyEquipmentService.java
+++ b/zhitan-system/src/main/java/com/zhitan/keyequipment/service/IYearKeyEquipmentService.java
@@ -9,12 +9,13 @@
import java.util.List;
/**
- *閲嶇偣璁惧鑳借�楃粺璁� 骞�
+ * 閲嶇偣璁惧鑳借�楃粺璁� 骞�
*
* @author sys
* @date 2021-01-11
*/
public interface IYearKeyEquipmentService {
- public List<YearKeyEquipment> getYearKeyEquipmentList(List<String> indexIds, List<TypeTime> dataList, Date beginTime, Date endTime, String timeType, String indexStorageId);
+ List<YearKeyEquipment> getYearKeyEquipmentList(List<String> indexIds, List<TypeTime> dataList, Date beginTime, Date endTime, String timeType, String indexStorageId);
+
List<YearKeyEquipment> getListChart(DataItemQueryDTO queryDto);
}
diff --git a/zhitan-system/src/main/resources/mapper/dailyprocessenergy/DailyProcessEnergyMapper.xml b/zhitan-system/src/main/resources/mapper/dailyprocessenergy/DailyProcessEnergyMapper.xml
index 4c64306..a8b42b9 100644
--- a/zhitan-system/src/main/resources/mapper/dailyprocessenergy/DailyProcessEnergyMapper.xml
+++ b/zhitan-system/src/main/resources/mapper/dailyprocessenergy/DailyProcessEnergyMapper.xml
@@ -59,7 +59,7 @@
AND di.index_id IN <foreach item="indexId" index="index" collection="indexIds" open="(" separator="," close=")">#{indexId} </foreach>
AND di.time_type = #{timeType}
<if test="indexStorageId !='' and indexStorageId !=null">
- and ci.equipment=#{indexStorageId}
+ and ci.energy_id=#{indexStorageId}
</if>
) aa
GROUP BY
diff --git a/zhitan-system/src/main/resources/mapper/dailyprocessenergy/MonthlyProcessEnergyMapper.xml b/zhitan-system/src/main/resources/mapper/dailyprocessenergy/MonthlyProcessEnergyMapper.xml
index 91e3016..544eba7 100644
--- a/zhitan-system/src/main/resources/mapper/dailyprocessenergy/MonthlyProcessEnergyMapper.xml
+++ b/zhitan-system/src/main/resources/mapper/dailyprocessenergy/MonthlyProcessEnergyMapper.xml
@@ -67,7 +67,7 @@
AND di.index_id IN <foreach item="indexId" index="index" collection="indexIds" open="(" separator="," close=")">#{indexId} </foreach>
AND di.time_type = #{timeType}
<if test="indexStorageId !='' and indexStorageId !=null">
- and ci.equipment=#{indexStorageId}
+ and ci.energy_id=#{indexStorageId}
</if>
) aa
GROUP BY
diff --git a/zhitan-system/src/main/resources/mapper/dailyprocessenergy/YearProcessEnergyMapper.xml b/zhitan-system/src/main/resources/mapper/dailyprocessenergy/YearProcessEnergyMapper.xml
index d94512b..e1a384f 100644
--- a/zhitan-system/src/main/resources/mapper/dailyprocessenergy/YearProcessEnergyMapper.xml
+++ b/zhitan-system/src/main/resources/mapper/dailyprocessenergy/YearProcessEnergyMapper.xml
@@ -48,7 +48,7 @@
AND di.index_id IN <foreach item="indexId" index="index" collection="indexIds" open="(" separator="," close=")">#{indexId} </foreach>
AND di.time_type = #{timeType}
<if test="indexStorageId !='' and indexStorageId !=null">
- and ci.equipment=#{indexStorageId}
+ and ci.energy_id=#{indexStorageId}
</if>
) aa
GROUP BY
diff --git a/zhitan-system/src/main/resources/mapper/keyequipment/DailyKeyEquipmentMapper.xml b/zhitan-system/src/main/resources/mapper/keyequipment/DailyKeyEquipmentMapper.xml
index 22c3ec2..3ddc977 100644
--- a/zhitan-system/src/main/resources/mapper/keyequipment/DailyKeyEquipmentMapper.xml
+++ b/zhitan-system/src/main/resources/mapper/keyequipment/DailyKeyEquipmentMapper.xml
@@ -59,7 +59,7 @@
AND di.index_id IN <foreach item="indexId" index="index" collection="indexIds" open="(" separator="," close=")">#{indexId} </foreach>
AND di.time_type = #{timeType}
<if test="indexStorageId !='' and indexStorageId !=null">
- and ci.equipment=#{indexStorageId}
+ and ci.energy_id=#{indexStorageId}
</if>
) aa
GROUP BY
diff --git a/zhitan-system/src/main/resources/mapper/keyequipment/MonthlyKeyEquipmentMapper.xml b/zhitan-system/src/main/resources/mapper/keyequipment/MonthlyKeyEquipmentMapper.xml
index 19f8a86..7e519d1 100644
--- a/zhitan-system/src/main/resources/mapper/keyequipment/MonthlyKeyEquipmentMapper.xml
+++ b/zhitan-system/src/main/resources/mapper/keyequipment/MonthlyKeyEquipmentMapper.xml
@@ -67,7 +67,7 @@
AND di.index_id IN <foreach item="indexId" index="index" collection="indexIds" open="(" separator="," close=")">#{indexId} </foreach>
AND di.time_type = #{timeType}
<if test="indexStorageId !='' and indexStorageId !=null">
- and ci.equipment=#{indexStorageId}
+ and ci.energy_id=#{indexStorageId}
</if>
) aa
GROUP BY
diff --git a/zhitan-system/src/main/resources/mapper/keyequipment/YearKeyEquipmentMapper.xml b/zhitan-system/src/main/resources/mapper/keyequipment/YearKeyEquipmentMapper.xml
index 3d4e35e..1777718 100644
--- a/zhitan-system/src/main/resources/mapper/keyequipment/YearKeyEquipmentMapper.xml
+++ b/zhitan-system/src/main/resources/mapper/keyequipment/YearKeyEquipmentMapper.xml
@@ -51,7 +51,7 @@
</foreach>
AND di.time_type = #{timeType}
<if test="indexStorageId !='' and indexStorageId !=null">
- and ci.equipment=#{indexStorageId}
+ and ci.energy_id=#{indexStorageId}
</if>
) aa
GROUP BY
--
Gitblit v1.9.3