diff --git a/src/hooks/roofcover/useRoofAllocationSetting.js b/src/hooks/roofcover/useRoofAllocationSetting.js index 671d4c7e..536a2127 100644 --- a/src/hooks/roofcover/useRoofAllocationSetting.js +++ b/src/hooks/roofcover/useRoofAllocationSetting.js @@ -446,12 +446,10 @@ export function useRoofAllocationSetting(id) { * 지붕재 변경 */ const handleChangeRoofMaterial = (value, index) => { - const selectedIndex = roofMaterials.findIndex((roof) => roof.selected) - const selectedRoofMaterial = roofMaterials.find((roof) => roof.roofMatlCd === value.id) const newRoofList = currentRoofList.map((roof, idx) => { if (idx === index) { - return { ...selectedRoofMaterial } + return { ...selectedRoofMaterial, selected: roof.selected } } return roof })