mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-06-17 10:47:36 +00:00
init duration
This commit is contained in:
parent
3ecf2afa1c
commit
5394e1eca8
@ -86,7 +86,7 @@ limitations under the License. -->
|
||||
<script lang="ts" setup>
|
||||
import { Themes } from "@/constants/data";
|
||||
import router from "@/router";
|
||||
import { useAppStoreWithOut } from "@/store/modules/app";
|
||||
import { useAppStoreWithOut, InitializationDurationRow } from "@/store/modules/app";
|
||||
import { useDashboardStore } from "@/store/modules/dashboard";
|
||||
import type { DashboardItem } from "@/types/dashboard";
|
||||
import timeFormat from "@/utils/timeFormat";
|
||||
@ -154,6 +154,7 @@ limitations under the License. -->
|
||||
day: appStore.metricsTTL.day,
|
||||
});
|
||||
}
|
||||
appStore.setDuration(InitializationDurationRow);
|
||||
}
|
||||
|
||||
function handleChangeTheme() {
|
||||
|
@ -43,14 +43,16 @@ interface AppState {
|
||||
recordsTTL: Recordable<RecordsTTL>;
|
||||
}
|
||||
|
||||
export const InitializationDurationRow = {
|
||||
start: new Date(new Date().getTime() - 1800000),
|
||||
end: new Date(),
|
||||
step: TimeType.MINUTE_TIME,
|
||||
};
|
||||
|
||||
export const appStore = defineStore({
|
||||
id: "app",
|
||||
state: (): AppState => ({
|
||||
durationRow: {
|
||||
start: new Date(new Date().getTime() - 1800000),
|
||||
end: new Date(),
|
||||
step: TimeType.MINUTE_TIME,
|
||||
},
|
||||
durationRow: InitializationDurationRow,
|
||||
utc: "",
|
||||
utcHour: 0,
|
||||
utcMin: 0,
|
||||
|
Loading…
Reference in New Issue
Block a user