Fixed #6780 - DynamicForm: DatePicker (range) not working

pull/7007/merge
Mert Sincan 2025-01-13 00:58:24 +00:00
parent d658d6fd4e
commit c30bba0a1a
1 changed files with 2 additions and 2 deletions

View File

@ -451,11 +451,11 @@ const classes = {
'p-datepicker-today': date.today
}
],
day: ({ instance, props, date }) => {
day: ({ instance, props, state, date }) => {
let selectedDayClass = '';
if (instance.isRangeSelection() && instance.isSelected(date) && date.selectable) {
selectedDayClass = instance.isDateEquals(props.modelValue[0], date) || instance.isDateEquals(props.modelValue[1], date) ? 'p-datepicker-day-selected' : 'p-datepicker-day-selected-range';
selectedDayClass = instance.isDateEquals(state.d_value[0], date) || instance.isDateEquals(state.d_value[1], date) ? 'p-datepicker-day-selected' : 'p-datepicker-day-selected-range';
}
return [