From eb80917ec31aa4a5085d77350ecb86cdb97c9782 Mon Sep 17 00:00:00 2001 From: hhjk00 Date: Mon, 20 Nov 2023 14:14:01 +0900 Subject: [PATCH] =?UTF-8?q?=EB=B9=84=ED=96=89=20=EC=8B=9C=EA=B0=84=20?= =?UTF-8?q?=ED=86=B5=EA=B3=84=20stepSize=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/containers/statistics/FlightContainer.js | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/containers/statistics/FlightContainer.js b/src/containers/statistics/FlightContainer.js index 1becdca..66fd92f 100644 --- a/src/containers/statistics/FlightContainer.js +++ b/src/containers/statistics/FlightContainer.js @@ -90,12 +90,16 @@ export default function FlightContainer() { const base = Math.pow(10, exponent); let stepSize; - if (max / base > 5) { - stepSize = base; - } else if (max / (base / 2) > 5) { - stepSize = base / 2; + if (searchType.category === 'TIME') { + stepSize = 3600; } else { - stepSize = base / 5; + if (max / base > 5) { + stepSize = base; + } else if (max / (base / 2) > 5) { + stepSize = base / 2; + } else { + stepSize = base / 5; + } } return stepSize;