diff --git a/src/main/kotlin/org/store/clothstar/product/domain/ItemAttribute.kt b/src/main/kotlin/org/store/clothstar/product/domain/ItemAttribute.kt index 505038a..e2d5dd1 100644 --- a/src/main/kotlin/org/store/clothstar/product/domain/ItemAttribute.kt +++ b/src/main/kotlin/org/store/clothstar/product/domain/ItemAttribute.kt @@ -8,7 +8,7 @@ import jakarta.persistence.Embeddable @Embeddable data class ItemAttribute( var optionId: Long, - var name: String, - var value: String, + var option: String, var valueId: Long, + var value: String, ) \ No newline at end of file diff --git a/src/main/kotlin/org/store/clothstar/product/dto/response/ProductResponse.kt b/src/main/kotlin/org/store/clothstar/product/dto/response/ProductResponse.kt index 122e9f2..91d30d5 100644 --- a/src/main/kotlin/org/store/clothstar/product/dto/response/ProductResponse.kt +++ b/src/main/kotlin/org/store/clothstar/product/dto/response/ProductResponse.kt @@ -138,7 +138,7 @@ class ItemAttributeResponse( fun from(attribute: ItemAttribute): ItemAttributeResponse { return ItemAttributeResponse( optionId = attribute.optionId, - name = attribute.name, + name = attribute.option, value = attribute.value, valueId = attribute.valueId ) diff --git a/src/main/kotlin/org/store/clothstar/product/service/ItemService.kt b/src/main/kotlin/org/store/clothstar/product/service/ItemService.kt index 6fccbb6..fac253c 100644 --- a/src/main/kotlin/org/store/clothstar/product/service/ItemService.kt +++ b/src/main/kotlin/org/store/clothstar/product/service/ItemService.kt @@ -58,7 +58,7 @@ class ItemService( attributes = optionValues.map { optionValue -> ItemAttribute( optionId = optionValue.productOption.productOptionId!!, - name = optionValue.productOption.optionName, + option = optionValue.productOption.optionName, value = optionValue.value, valueId = optionValue.optionValueId!! )