Skip to content

Commit

Permalink
fix(frontend): 健康报告默认筛选时间为今天 #3696
Browse files Browse the repository at this point in the history
  • Loading branch information
hLinx authored and zhangzhw8 committed Mar 28, 2024
1 parent d659f53 commit e52fd8a
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,10 @@
const emits = defineEmits<Emits>();
const genDefaultData = () => ({
create_at__gte: '',
create_at__lte: '',
create_at__gte: dayjs().startOf('day')
.format('YYYY-MM-DD HH:mm:ss'),
create_at__lte: dayjs().endOf('day')
.format('YYYY-MM-DD HH:mm:ss'),
cluster: '',
status: '',
});
Expand All @@ -87,7 +89,9 @@
const serachParams = getSearchParams();
Object.keys(formData).forEach((key) => {
formData[key as keyof typeof formData] = serachParams[key];
if (serachParams[key] !== undefined) {
formData[key as keyof typeof formData] = serachParams[key];
}
});
const { data: clusterList } = useRequest(queryAllTypeCluster, {
Expand Down

0 comments on commit e52fd8a

Please sign in to comment.