diff --git a/app/src/main/java/com/teumteum/teumteum/presentation/signup/fix/CardFixFragment.kt b/app/src/main/java/com/teumteum/teumteum/presentation/signup/fix/CardFixFragment.kt index af097edb..97dc265e 100644 --- a/app/src/main/java/com/teumteum/teumteum/presentation/signup/fix/CardFixFragment.kt +++ b/app/src/main/java/com/teumteum/teumteum/presentation/signup/fix/CardFixFragment.kt @@ -78,9 +78,9 @@ class CardFixFragment val bc = BackCard(goalContent = goalText.value, characterResId = SignupUtils.CHARACTER_CARD_LIST_BACK[characterId.value]) binding.cardviewBack.getInstance(bc) binding.cardviewBack.apply { - submitInterestList(interests) isModify = false setIsModifyDetail(true) + submitInterestList(interests) } } } @@ -199,7 +199,7 @@ class CardFixFragment if (!isFirstLoaded) { val selfArray = resources.getStringArray(R.array.interest_1) val fieldArray = resources.getStringArray(R.array.interest_2) - viewModel.setAllInterests(interests.map { it.toString() }, selfArray, fieldArray) + viewModel.setAllInterests(interests.map { it.interest.toString() }, selfArray, fieldArray) } isFirstLoaded = false } diff --git a/app/src/main/java/com/teumteum/teumteum/util/custom/view/BackCardView.kt b/app/src/main/java/com/teumteum/teumteum/util/custom/view/BackCardView.kt index fe772838..57250dfa 100644 --- a/app/src/main/java/com/teumteum/teumteum/util/custom/view/BackCardView.kt +++ b/app/src/main/java/com/teumteum/teumteum/util/custom/view/BackCardView.kt @@ -75,7 +75,8 @@ class BackCardView : CardView, OnCurrentListChangedListener { fun submitInterestList(interests: List) { val currentList = interestAdapter.currentList.toMutableList() - if (!currentList.any { it.interest == "추가하기" } && isModifyDetail) { + if (isModifyDetail) { + currentList.removeAll { it.interest == "추가하기" } currentList.add(Interest("추가하기")) }