Skip to content

Commit ded532f

Browse files
committed
add :: JsonProperty 추가
1 parent 6cf0b02 commit ded532f

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

src/main/kotlin/com/msg/gauth/domain/user/presentation/dto/response/SingleAcceptedUserResDto.kt

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,17 @@
11
package com.msg.gauth.domain.user.presentation.dto.response
22

3+
import com.fasterxml.jackson.annotation.JsonCreator
4+
import com.fasterxml.jackson.annotation.JsonProperty
35
import com.msg.gauth.domain.user.User
46

5-
data class SingleAcceptedUserResDto(
6-
val id: Long,
7-
val name: String,
8-
val email: String,
9-
val grade: Int?,
10-
val classNum: Int?,
11-
val num: Int?,
12-
val profileUrl: String?
7+
data class SingleAcceptedUserResDto @JsonCreator constructor(
8+
@JsonProperty("id") val id: Long,
9+
@JsonProperty("name") val name: String,
10+
@JsonProperty("email") val email: String,
11+
@JsonProperty("grade") val grade: Int?,
12+
@JsonProperty("classNum") val classNum: Int?,
13+
@JsonProperty("num") val num: Int?,
14+
@JsonProperty("profileUrl") val profileUrl: String?
1315
) {
1416

1517
constructor(user: User) : this(

0 commit comments

Comments
 (0)