幸运礼物-后台-统计-修改时区换算
This commit is contained in:
@@ -190,12 +190,12 @@ public class Lucky24PoolAdminService {
|
||||
bizExecutor.execute(()->{
|
||||
try {
|
||||
Date startTime = DateTimeUtil.getBeginTimeOfDay(DateTimeUtil.convertStrToDate(endDate, DateTimeUtil.DEFAULT_DATE_PATTERN));
|
||||
ZonedDateTime zonedStartTime = startTime.toInstant().atZone(ZoneId.of(partitionInfo.getZoneId()));
|
||||
Date systemStartTime = Date.from(zonedStartTime.withZoneSameLocal(ZoneId.systemDefault()).toInstant());
|
||||
ZonedDateTime zonedStartTime = startTime.toInstant().atZone(ZoneId.systemDefault());
|
||||
Date systemStartTime = Date.from(zonedStartTime.withZoneSameLocal(ZoneId.of(partitionInfo.getZoneId())).toInstant());
|
||||
long zoneIdHour = Duration.between(systemStartTime.toInstant(), startTime.toInstant()).toHours();
|
||||
Date endTime = DateTimeUtil.getEndTimeOfDay(DateTimeUtil.convertStrToDate(endDate, DateTimeUtil.DEFAULT_DATE_PATTERN));
|
||||
ZonedDateTime zonedEndTime = endTime.toInstant().atZone(ZoneId.of(partitionInfo.getZoneId()));
|
||||
Date systemEndTime = Date.from(zonedEndTime.withZoneSameLocal(ZoneId.systemDefault()).toInstant());
|
||||
ZonedDateTime zonedEndTime = endTime.toInstant().atZone(ZoneId.systemDefault());
|
||||
Date systemEndTime = Date.from(zonedEndTime.withZoneSameLocal(ZoneId.of(partitionInfo.getZoneId())).toInstant());
|
||||
List<Lucky24PlatformStat> list = recordMapper.listPlatform(partitionId, systemStartTime, systemEndTime, zoneIdHour);
|
||||
for (Lucky24PlatformStat stat: list) {
|
||||
statMap.put(stat.getDate(), stat);
|
||||
@@ -379,12 +379,12 @@ public class Lucky24PoolAdminService {
|
||||
private List<Lucky24PersonalStat> listPersonal(int partitionId, String zonedId, Long uid, String date) {
|
||||
ZoneId zoneId = ZoneId.of(zonedId);
|
||||
Date startTime = DateTimeUtil.getBeginTimeOfDay(DateTimeUtil.convertStrToDate(date, DateTimeUtil.DEFAULT_DATE_PATTERN));
|
||||
ZonedDateTime zonedStartTime = startTime.toInstant().atZone(zoneId);
|
||||
Date systemStartTime = Date.from(zonedStartTime.withZoneSameLocal(ZoneId.systemDefault()).toInstant());
|
||||
ZonedDateTime zonedStartTime = startTime.toInstant().atZone(ZoneId.systemDefault());
|
||||
Date systemStartTime = Date.from(zonedStartTime.withZoneSameLocal(zoneId).toInstant());
|
||||
long zoneIdHour = Duration.between(systemStartTime.toInstant(), startTime.toInstant()).toHours();
|
||||
Date endTime = DateTimeUtil.getEndTimeOfDay(DateTimeUtil.convertStrToDate(date, DateTimeUtil.DEFAULT_DATE_PATTERN));
|
||||
ZonedDateTime zonedEndTime = endTime.toInstant().atZone(zoneId);
|
||||
Date systemEndTime = Date.from(zonedEndTime.withZoneSameLocal(ZoneId.systemDefault()).toInstant());
|
||||
ZonedDateTime zonedEndTime = endTime.toInstant().atZone(ZoneId.systemDefault());
|
||||
Date systemEndTime = Date.from(zonedEndTime.withZoneSameLocal(zoneId).toInstant());
|
||||
return recordMapper.listPersonal(partitionId, uid, systemStartTime, systemEndTime, zoneIdHour);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user