Explorar o código

计算电量调整

xieshengjie hai 1 ano
pai
achega
f551453789

+ 1 - 1
web/runeconomy-xk/src/main/java/com/gyee/runeconomy/service/monitor/StationMonitorService.java

@@ -187,7 +187,7 @@ public class StationMonitorService {
 
         QueryWrapper<ProEconPowerstationInfoDay1> qw = new QueryWrapper<>();
         qw.lambda().le(ProEconPowerstationInfoDay1::getRecordDate, DateUtils.today()).ge(ProEconPowerstationInfoDay1::getRecordDate, DateUtils.getMonthFirst(DateUtils.today()));
-        qw.lambda().eq(ProEconPowerstationInfoDay1::getForeignKeyId,wpid);
+        qw.lambda().eq(ProEconPowerstationInfoDay1::getForeignKeyId,wpid).orderByAsc(ProEconPowerstationInfoDay1::getRecordDate);
         List<ProEconPowerstationInfoDay1> list = proEconPowerstationInfoDay1Service.list(qw);
         return list;
     }

+ 3 - 3
web/runeconomy-xk/src/main/java/com/gyee/runeconomy/util/DateUtils.java

@@ -34,7 +34,7 @@ public class DateUtils {
             df = new SimpleDateFormat(format);
             threadLocal.set(df);
         }
-
+        df.setLenient(false);
         return df;
 
     }
@@ -47,7 +47,7 @@ public class DateUtils {
             df1 = new SimpleDateFormat(format1);
             threadLocal.set(df1);
         }
-
+        df1.setLenient(false);
         return df1;
 
     }
@@ -60,7 +60,7 @@ public class DateUtils {
             df2 = new SimpleDateFormat(format2);
             threadLocal.set(df2);
         }
-
+        df2.setLenient(false);
         return df2;
 
     }