日历表格调整

This commit is contained in:
stt
2025-11-26 09:31:32 +08:00
parent 67d9aaf958
commit cf51ba9ff0
3 changed files with 62 additions and 58 deletions

View File

@@ -88,6 +88,7 @@ interface Props {
theCurrentTime?: boolean //控制时间前3天展示上个月时间
showReset?: boolean //是否显示重置
showExport?: boolean //导出控制
timeCacheFlag?: boolean //是否取缓存时间
}
const props = withDefaults(defineProps<Props>(), {
@@ -97,7 +98,8 @@ const props = withDefaults(defineProps<Props>(), {
nextFlag: false,
theCurrentTime: true,
showReset: true,
showExport: false
showExport: false,
timeCacheFlag: true
})
// 处理 DatePicker 值变化事件
@@ -134,7 +136,7 @@ onMounted(() => {
if (props.datePicker && datePickerRef.value) {
// 从缓存中获取值并设置
const cached = timeCacheStore.getCache(route.path)
if (cached) {
if (props.timeCacheFlag && cached) {
if (cached.interval !== undefined) {
datePickerRef.value.setInterval(cached.interval)
}