From c6e85d5b57090f6d607f461f2f6fc20f496b29fd Mon Sep 17 00:00:00 2001 From: CaIon <1808837298@qq.com> Date: Thu, 18 Apr 2024 19:37:52 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=AE=8C=E5=96=84=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E7=9C=8B=E6=9D=BF=20#190?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- web/src/pages/Detail/index.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/web/src/pages/Detail/index.js b/web/src/pages/Detail/index.js index ccc07c13..f334dd3f 100644 --- a/web/src/pages/Detail/index.js +++ b/web/src/pages/Detail/index.js @@ -72,6 +72,7 @@ const Detail = (props) => { stack: true, legends: { visible: true, + selectMode: 'single', }, title: { visible: true, @@ -216,6 +217,8 @@ const Detail = (props) => { } else if (dataExportDefaultTime === 'week') { timeGranularity = 604800; } + // sort created_at + data.sort((a, b) => a.created_at - b.created_at); data.forEach((item) => { item['created_at'] = Math.floor(item['created_at'] / timeGranularity) * timeGranularity;