fix(mypage): 쿠폰 버튼 노출과 인증 분기를 조정한다
This commit is contained in:
@@ -403,7 +403,33 @@ class MyPageFragment : BaseFragment<FragmentMyBinding>(FragmentMyBinding::inflat
|
||||
binding.btnIdentityVerification.root.visibility = View.INVISIBLE
|
||||
}
|
||||
|
||||
if (it.isAuth) {
|
||||
binding.ivProfile.load(it.profileUrl) {
|
||||
crossfade(true)
|
||||
placeholder(R.drawable.ic_place_holder)
|
||||
transformations(CircleCropTransformation())
|
||||
}
|
||||
binding.tvNickname.text = it.nickname
|
||||
|
||||
binding.tvCanAmount.text = (it.chargeCan + it.rewardCan).moneyFormat()
|
||||
binding.tvPointAmount.text = it.point.moneyFormat()
|
||||
|
||||
val shouldShowCouponButton = if (isKoreanUser) {
|
||||
true
|
||||
} else {
|
||||
SharedPreferenceManager.isAdultContentVisible
|
||||
}
|
||||
|
||||
binding.btnCoupon.root.visibility = if (shouldShowCouponButton) {
|
||||
View.VISIBLE
|
||||
} else {
|
||||
View.GONE
|
||||
}
|
||||
|
||||
if (!shouldShowCouponButton) {
|
||||
return@observe
|
||||
}
|
||||
|
||||
if (it.isAuth || !isKoreanUser) {
|
||||
FunctionButtonHelper.setupFunctionButton(
|
||||
buttonView = binding.btnCoupon.root,
|
||||
iconRes = R.drawable.ic_my_coupon,
|
||||
@@ -431,16 +457,6 @@ class MyPageFragment : BaseFragment<FragmentMyBinding>(FragmentMyBinding::inflat
|
||||
showAuthDialog()
|
||||
}
|
||||
}
|
||||
|
||||
binding.ivProfile.load(it.profileUrl) {
|
||||
crossfade(true)
|
||||
placeholder(R.drawable.ic_place_holder)
|
||||
transformations(CircleCropTransformation())
|
||||
}
|
||||
binding.tvNickname.text = it.nickname
|
||||
|
||||
binding.tvCanAmount.text = (it.chargeCan + it.rewardCan).moneyFormat()
|
||||
binding.tvPointAmount.text = it.point.moneyFormat()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user