From 10ee4f989056cfe64cc19c0a9a186df53c633247 Mon Sep 17 00:00:00 2001 From: EunJiJung Date: Sun, 24 Nov 2024 00:00:29 +0900 Subject: [PATCH] =?UTF-8?q?refactor/#137=20:=20=E2=99=BB=EF=B8=8F=203.2=20?= =?UTF-8?q?=EA=B0=80=EA=B2=8C=20=EC=83=81=EC=84=B8=20=EC=A0=95=EB=B3=B4=20?= =?UTF-8?q?=EC=A1=B0=ED=9A=8C=20=EA=B0=80=EA=B2=8C=20=ED=9E=88=EC=8A=A4?= =?UTF-8?q?=ED=86=A0=EB=A6=AC=20ASC=20->=20DESC=EB=A1=9C=20=EB=B3=80?= =?UTF-8?q?=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: EunJiJung --- .../account/application/service/ReadStoreDetailService.java | 2 +- .../onjung/account/repository/mysql/StoreHistoryRepository.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/daon/onjung/account/application/service/ReadStoreDetailService.java b/src/main/java/com/daon/onjung/account/application/service/ReadStoreDetailService.java index cac4052..7bbdc6f 100644 --- a/src/main/java/com/daon/onjung/account/application/service/ReadStoreDetailService.java +++ b/src/main/java/com/daon/onjung/account/application/service/ReadStoreDetailService.java @@ -69,7 +69,7 @@ public ReadStoreDetailResponseDto execute(Long id) { totalShareCount ); - List storeHistories = storeHistoryRepository.findByStoreOrderByActionDateAsc(store); + List storeHistories = storeHistoryRepository.findByStoreOrderByActionDateDesc(store); // 그룹화: actionDate를 기준으로 그룹화 Map> groupedByYearMonth = storeHistories.stream() diff --git a/src/main/java/com/daon/onjung/account/repository/mysql/StoreHistoryRepository.java b/src/main/java/com/daon/onjung/account/repository/mysql/StoreHistoryRepository.java index 9e1967b..7215959 100644 --- a/src/main/java/com/daon/onjung/account/repository/mysql/StoreHistoryRepository.java +++ b/src/main/java/com/daon/onjung/account/repository/mysql/StoreHistoryRepository.java @@ -9,5 +9,5 @@ @Repository public interface StoreHistoryRepository extends JpaRepository { - List findByStoreOrderByActionDateAsc(Store store); + List findByStoreOrderByActionDateDesc(Store store); }