mirror of
https://gitee.com/vant-contrib/vant-weapp.git
synced 2025-04-06 03:58:05 +08:00
fix(Calendar): fix timezone
This commit is contained in:
parent
d4f4d75fd9
commit
3b120e3c5b
@ -6,9 +6,10 @@ function getMonths(minDate, maxDate) {
|
||||
var cursor = getDate(minDate);
|
||||
|
||||
cursor.setDate(1);
|
||||
cursor.setMinutes(cursor.getMinutes() - cursor.getTimezoneOffset())
|
||||
|
||||
do {
|
||||
months.push(cursor.valueOf());
|
||||
months.push(cursor.getTime());
|
||||
cursor.setMonth(cursor.getMonth() + 1);
|
||||
} while (utils.compareMonth(cursor, getDate(maxDate)) !== 1);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user