Skip to content

Commit 1a5af45

Browse files
author
Irfan Maulana
committed
Merge branch 'master' of github.com:mazipan/vue-rangedate-picker
2 parents 4131f48 + e54ad8c commit 1a5af45

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/js/rangedate-picker.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,13 +49,14 @@ const defaultStyle = {
4949
const defaultPresets = {
5050
today: function () {
5151
const n = new Date()
52-
const today = new Date(n.getFullYear(), n.getMonth(), n.getDate() + 1)
52+
const startToday = new Date(n.getFullYear(), n.getMonth(), n.getDate() + 1, 0, 0)
53+
const endToday = new Date(n.getFullYear(), n.getMonth(), n.getDate() + 1, 23, 59)
5354
return {
5455
label: presetRangeLabel[defaultI18n].today,
5556
active: false,
5657
dateRange: {
57-
start: today,
58-
end: today
58+
start: startToday,
59+
end: endToday
5960
}
6061
}
6162
},

0 commit comments

Comments
 (0)