Skip to content

Commit 844148b

Browse files
author
yaroslav8765
committed
fix: fix clear all button in filters, when we use date range
1 parent 6e873e9 commit 844148b

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

adminforth/spa/src/components/CustomDateRangePicker.vue

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,10 +169,13 @@ function updateFromProps() {
169169
startDate.value = date.toString();
170170
}
171171
172-
if (!props.valueEnd) {
172+
if (!props.valueEnd || props.valueEnd === '' || props.valueEnd === null) {
173173
datepickerEndEl.value.value = '';
174174
endTime.value = '';
175-
} else if (props.column.type === 'time') {
175+
endDate.value = '';
176+
return;
177+
}
178+
if (props.column.type === 'time') {
176179
endTime.value = props.valueEnd;
177180
} else {
178181
const date = dayjs(props.valueEnd);

0 commit comments

Comments
 (0)