From 35b16d737018ba7a93d11a537deae04b97842acf Mon Sep 17 00:00:00 2001 From: Klaus Date: Wed, 30 Sep 2026 13:38:24 +0900 Subject: [PATCH] =?UTF-8?q?feat(gift):=20=EC=84=A0=EB=AC=BC=20=EC=8B=A0?= =?UTF-8?q?=EC=B2=AD=20=EC=9A=94=EC=B2=AD=20DTO=EB=A5=BC=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80=ED=95=9C=EB=8B=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../v2/api/gift/dto/GiftApplicationRequest.kt | 32 +++++++++++++++++++ ...GiftRecipientAddressRegistrationRequest.kt | 23 +++++++++++++ .../v2/api/gift/dto/GiftReviewRequest.kt | 15 +++++++++ .../dto/GiftTrackingRegistrationRequest.kt | 13 ++++++++ 4 files changed, 83 insertions(+) create mode 100644 src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftApplicationRequest.kt create mode 100644 src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftRecipientAddressRegistrationRequest.kt create mode 100644 src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftReviewRequest.kt create mode 100644 src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftTrackingRegistrationRequest.kt diff --git a/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftApplicationRequest.kt b/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftApplicationRequest.kt new file mode 100644 index 00000000..fbccf62e --- /dev/null +++ b/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftApplicationRequest.kt @@ -0,0 +1,32 @@ +package kr.co.vividnext.sodalive.v2.api.gift.dto + +import kr.co.vividnext.sodalive.v2.gift.application.GiftApplicationCommand +import kr.co.vividnext.sodalive.v2.gift.domain.GiftSize + +data class GiftApplicationRequest( + val recipientMemberId: Long, + val senderName: String, + val senderPhoneNumber: String, + val senderZipCode: String, + val senderAddress: String, + val senderAddressDetail: String?, + val sizeCode: GiftSize, + val categoryId: Long, + val senderTermsAgreed: Boolean, + val senderPrivacyAgreed: Boolean, + val damageWaiverAgreed: Boolean +) { + fun toCommand() = GiftApplicationCommand( + recipientMemberId = recipientMemberId, + senderName = senderName, + senderPhoneNumber = senderPhoneNumber, + senderZipCode = senderZipCode, + senderAddress = senderAddress, + senderAddressDetail = senderAddressDetail, + sizeCode = sizeCode, + categoryId = categoryId, + senderTermsAgreed = senderTermsAgreed, + senderPrivacyAgreed = senderPrivacyAgreed, + damageWaiverAgreed = damageWaiverAgreed + ) +} diff --git a/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftRecipientAddressRegistrationRequest.kt b/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftRecipientAddressRegistrationRequest.kt new file mode 100644 index 00000000..8617032e --- /dev/null +++ b/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftRecipientAddressRegistrationRequest.kt @@ -0,0 +1,23 @@ +package kr.co.vividnext.sodalive.v2.api.gift.dto + +import kr.co.vividnext.sodalive.v2.gift.application.GiftRecipientAddressRegistrationCommand + +data class GiftRecipientAddressRegistrationRequest( + val recipientName: String, + val recipientPhoneNumber: String, + val recipientZipCode: String, + val recipientAddress: String, + val recipientAddressDetail: String?, + val recipientTermsAgreed: Boolean, + val recipientPrivacyAgreed: Boolean +) { + fun toCommand() = GiftRecipientAddressRegistrationCommand( + name = recipientName, + phoneNumber = recipientPhoneNumber, + zipCode = recipientZipCode, + address = recipientAddress, + addressDetail = recipientAddressDetail, + recipientTermsAgreed = recipientTermsAgreed, + recipientPrivacyAgreed = recipientPrivacyAgreed + ) +} diff --git a/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftReviewRequest.kt b/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftReviewRequest.kt new file mode 100644 index 00000000..9825e279 --- /dev/null +++ b/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftReviewRequest.kt @@ -0,0 +1,15 @@ +package kr.co.vividnext.sodalive.v2.api.gift.dto + +import kr.co.vividnext.sodalive.v2.gift.application.GiftReviewCommand + +data class GiftReviewRequest( + val rating: Int, + val keywords: List, + val comment: String? +) { + fun toCommand() = GiftReviewCommand( + rating = rating, + keywords = keywords, + comment = comment + ) +} diff --git a/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftTrackingRegistrationRequest.kt b/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftTrackingRegistrationRequest.kt new file mode 100644 index 00000000..59db2ecd --- /dev/null +++ b/src/main/kotlin/kr/co/vividnext/sodalive/v2/api/gift/dto/GiftTrackingRegistrationRequest.kt @@ -0,0 +1,13 @@ +package kr.co.vividnext.sodalive.v2.api.gift.dto + +import kr.co.vividnext.sodalive.v2.gift.application.GiftTrackingRegistrationCommand + +data class GiftTrackingRegistrationRequest( + val courierCompanyName: String, + val trackingNumber: String +) { + fun toCommand() = GiftTrackingRegistrationCommand( + courierCompanyName = courierCompanyName, + trackingNumber = trackingNumber + ) +}