diff --git a/packages/calendar/index.ts b/packages/calendar/index.ts index 4033efce..ab3e16de 100644 --- a/packages/calendar/index.ts +++ b/packages/calendar/index.ts @@ -211,14 +211,14 @@ VantComponent({ const [startDay, endDay] = defaultDate || []; + const startDate = getTime(startDay || now); const start = this.limitDateRange( - startDay || now, + startDate, minDate, - getPrevDay(new Date(maxDate)).getTime() + allowSameDay ? startDate : getPrevDay(new Date(maxDate)).getTime() ); const date = getTime(endDay || now); - const end = this.limitDateRange( date, allowSameDay ? date : getNextDay(new Date(minDate)).getTime()