From 89b0e4635dab96bba4efbe39db2f9f7526375cc1 Mon Sep 17 00:00:00 2001 From: lcw729 Date: Wed, 5 Jun 2024 16:40:31 +0900 Subject: [PATCH] =?UTF-8?q?feat:=20=EB=AA=85=EC=86=8C(=EC=9E=A5=EC=86=8C)?= =?UTF-8?q?=20=ED=95=9C=EA=B5=AD=20=EC=9D=B4=EB=A6=84=20=EC=97=86=EB=8A=94?= =?UTF-8?q?=20=EA=B2=BD=EC=9A=B0,=20=EC=98=81=EC=96=B4=EB=A1=9C=20?= =?UTF-8?q?=EB=B0=98=ED=99=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/hanaro/triptogether/place/domain/PlaceEntity.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/hanaro/triptogether/place/domain/PlaceEntity.java b/src/main/java/com/hanaro/triptogether/place/domain/PlaceEntity.java index c838f86..82c98bf 100644 --- a/src/main/java/com/hanaro/triptogether/place/domain/PlaceEntity.java +++ b/src/main/java/com/hanaro/triptogether/place/domain/PlaceEntity.java @@ -9,6 +9,7 @@ import lombok.AllArgsConstructor; import lombok.Builder; import lombok.NoArgsConstructor; +import org.springframework.util.StringUtils; @Entity @Table(name = "Place") @@ -51,10 +52,12 @@ public class PlaceEntity { private Member deletedBy; public Place toPlace() { + String placeNameKo = StringUtils.hasText(this.placeNameKo) ? this.placeNameKo : this.placeNameEng; + return Place.builder() .placeIdx(this.placeIdx) .cityIdx(this.city.getCityIdx()) - .placeNameKo(this.placeNameKo) + .placeNameKo(placeNameKo) .placeNameEng(this.placeNameEng) .placeImg(this.placeImg) .categoryIdx(this.categoryIdx)