You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by wu...@apache.org on 2022/07/21 02:06:55 UTC

[skywalking-booster-ui] branch main updated: fix short time range (#125)

This is an automated email from the ASF dual-hosted git repository.

wusheng pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/skywalking-booster-ui.git


The following commit(s) were added to refs/heads/main by this push:
     new c7079ea  fix short time range (#125)
c7079ea is described below

commit c7079ea17c6da07de72d132e29464a20d8353fda
Author: Fine0830 <fi...@outlook.com>
AuthorDate: Thu Jul 21 10:06:51 2022 +0800

    fix short time range (#125)
---
 src/views/dashboard/related/event/Content.vue | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/src/views/dashboard/related/event/Content.vue b/src/views/dashboard/related/event/Content.vue
index 36511ee..5dc8c50 100644
--- a/src/views/dashboard/related/event/Content.vue
+++ b/src/views/dashboard/related/event/Content.vue
@@ -42,8 +42,6 @@ const visGraph = ref<Nullable<any>>(null);
 const oldVal = ref<{ width: number; height: number }>({ width: 0, height: 0 });
 const dashboardStore = useDashboardStore();
 const appStore = useAppStoreWithOut();
-const dateFormat = (date: number, pattern = "YYYY-MM-DD HH:mm:ss") =>
-  new Date(dayjs(date).format(pattern));
 const visDate = (date: number, pattern = "YYYY-MM-DD HH:mm:ss") =>
   dayjs(date).format(pattern);
 
@@ -67,8 +65,8 @@ function visTimeline() {
     return {
       id: index + 1,
       content: d.name,
-      start: dateFormat(Number(d.startTime)),
-      end: dateFormat(Number(d.endTime)),
+      start: new Date(Number(d.startTime)),
+      end: new Date(Number(d.endTime)),
       data: d,
       className: d.type,
     };