mirror of https://github.com/apache/cloudstack.git
CLOUDSTACK-5404: Fix timezone bug in network usage
This commit is contained in:
parent
15cec79b5e
commit
d5277a81e6
|
|
@ -18,7 +18,6 @@ package com.cloud.usage.dao;
|
|||
|
||||
import java.sql.PreparedStatement;
|
||||
import java.sql.ResultSet;
|
||||
import java.sql.Timestamp;
|
||||
import java.sql.Types;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
|
|
@ -428,8 +427,8 @@ public class UsageDaoImpl extends GenericDaoBase<UsageVO, Long> implements Usage
|
|||
} else {
|
||||
pstmt.setNull(15, Types.BIGINT);
|
||||
}
|
||||
pstmt.setTimestamp(16, new Timestamp(usageRecord.getStartDate().getTime()));
|
||||
pstmt.setTimestamp(17, new Timestamp(usageRecord.getEndDate().getTime()));
|
||||
pstmt.setString(16, DateUtil.getDateDisplayString(s_gmtTimeZone, usageRecord.getStartDate()));
|
||||
pstmt.setString(17, DateUtil.getDateDisplayString(s_gmtTimeZone, usageRecord.getEndDate()));
|
||||
if(usageRecord.getVirtualSize() != null){
|
||||
pstmt.setLong(18, usageRecord.getSize());
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in New Issue