From b6e9a5f15d63e8a2ce9075707e87412968b98d68 Mon Sep 17 00:00:00 2001 From: Minjae-An Date: Wed, 8 May 2024 22:08:19 +0900 Subject: [PATCH] =?UTF-8?q?feat:=20=EC=82=AC=EC=9A=A9=20=EC=A4=91=EC=9D=B8?= =?UTF-8?q?=20=EC=A0=84=ED=99=94=EB=B2=88=ED=98=B8=20=EA=B2=80=EC=A6=9D=20?= =?UTF-8?q?=EC=9A=94=EC=B2=AD=20DTO=20=EC=B6=94=EA=B0=80(#78)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../UserValidateUsedPhoneNumberRequest.java | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 be/src/main/java/yeonba/be/login/dto/request/UserValidateUsedPhoneNumberRequest.java diff --git a/be/src/main/java/yeonba/be/login/dto/request/UserValidateUsedPhoneNumberRequest.java b/be/src/main/java/yeonba/be/login/dto/request/UserValidateUsedPhoneNumberRequest.java new file mode 100644 index 00000000..da0d2535 --- /dev/null +++ b/be/src/main/java/yeonba/be/login/dto/request/UserValidateUsedPhoneNumberRequest.java @@ -0,0 +1,24 @@ +package yeonba.be.login.dto.request; + +import io.swagger.v3.oas.annotations.Parameter; +import io.swagger.v3.oas.annotations.enums.ParameterIn; +import jakarta.validation.constraints.NotBlank; +import jakarta.validation.constraints.Pattern; +import lombok.AllArgsConstructor; +import lombok.Getter; + +@Getter +@AllArgsConstructor +public class UserValidateUsedPhoneNumberRequest { + + @Parameter( + name = "phoneNumber", + description = "전화번호", + example = "01011112222", + in = ParameterIn.QUERY) + @Pattern( + regexp = "^010\\d{8}$", + message = "전화번호는 11자리 010으로 시작하며 하이픈(-) 없이 0~9의 숫자로 이뤄져야 합니다.") + @NotBlank(message = "전화번호는 반드시 입력되어야 합니다.") + private String phoneNumber; +}