1
mirror of https://github.com/monero-project/monero-gui synced 2024-11-16 14:55:33 +01:00

Merge pull request #2349

1ec22b3 history: fix start/end of the day calculation, apply local timezone (xiphon)
This commit is contained in:
luigi1111 2019-08-14 15:52:02 -05:00
commit 562c46660a
No known key found for this signature in database
GPG Key ID: F4ACA0183641E010

View File

@ -1361,8 +1361,9 @@ Rectangle {
// applying filters
root.txData = JSON.parse(JSON.stringify(root.txModelData)); // deepcopy
var fromDate = fromDatePicker.currentDate.getTime() / 1000;
var toDate = toDatePicker.currentDate.getTime() / 1000;
const timezoneOffset = new Date().getTimezoneOffset() * 60;
var fromDate = Math.floor(fromDatePicker.currentDate.getTime() / 86400000) * 86400 + timezoneOffset;
var toDate = (Math.floor(toDatePicker.currentDate.getTime() / 86400000) + 1) * 86400 + timezoneOffset;
var txs = [];
for (var i = 0; i < root.txData.length; i++){