mirror of
https://github.com/dataease/dataease.git
synced 2026-05-18 09:48:10 +08:00
fix(查询组件): 时间范围组件再选择时间范围后切换浏览器tab页导致在此查看,选项依旧处于展示状态
This commit is contained in:
@@ -241,8 +241,13 @@ const calendarChange = val => {
|
||||
startWindowTime.value = +new Date(val[0])
|
||||
}
|
||||
|
||||
const visibleChange = () => {
|
||||
const datePicker = ref()
|
||||
|
||||
const visibleChange = (visible: boolean) => {
|
||||
startWindowTime.value = 0
|
||||
if (!visible) {
|
||||
datePicker.value?.blur()
|
||||
}
|
||||
}
|
||||
|
||||
const queryTimeType = computed(() => {
|
||||
@@ -471,6 +476,7 @@ const formatDate = computed(() => {
|
||||
:key="config.timeGranularityMultiple"
|
||||
:type="config.timeGranularityMultiple"
|
||||
:style="selectStyle"
|
||||
ref="datePicker"
|
||||
@visible-change="visibleChange"
|
||||
:disabled-date="disabledDate"
|
||||
@calendar-change="calendarChange"
|
||||
|
||||
Reference in New Issue
Block a user