Skip to content

Commit

Permalink
Merge pull request #21 from ttoklip/faet/#2_마이페이지_구현
Browse files Browse the repository at this point in the history
Faet/#2 마이페이지 구현
  • Loading branch information
hangunhee39 authored Jan 30, 2024
2 parents 773b1fb + 9903994 commit 7cadcbb
Show file tree
Hide file tree
Showing 42 changed files with 2,061 additions and 111 deletions.
32 changes: 31 additions & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,19 @@
<application
android:name=".TtoklipApplication"
android:allowBackup="true"
android:usesCleartextTraffic="true"
android:dataExtractionRules="@xml/data_extraction_rules"
android:fullBackupContent="@xml/backup_rules"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/Theme.Ttoklip"
android:usesCleartextTraffic="true"
tools:targetApi="31">

<activity
android:name=".presentation.mypage.ManageMyInfoActivity"
android:screenOrientation="portrait"
android:exported="false" />
<activity
android:name=".presentation.honeytip.read.ReadActivity"
Expand All @@ -38,15 +39,44 @@
android:exported="false" />
<activity
android:name=".presentation.mypage.SetAnnouncementActivity"
android:screenOrientation="portrait"
android:exported="false" />
<activity
android:name=".presentation.mypage.ManageUsageActivity"
android:screenOrientation="portrait"
android:exported="false" />
<activity
android:name=".presentation.mypage.MyHometownAddressActivity"
android:screenOrientation="portrait"
android:exported="false" />
<activity
android:name=".presentation.mypage.ManageAccountActivity"
android:screenOrientation="portrait"
android:windowSoftInputMode="adjustResize"
android:exported="false" />
<activity
android:name=".presentation.mypage.NoticeSettingActivity"
android:screenOrientation="portrait"
android:exported="false" />
<activity
android:name=".presentation.mypage.CustomerServiceCenterActivity"
android:screenOrientation="portrait"
android:exported="false" />
<activity
android:name=".presentation.mypage.TermsPolicesActivity"
android:screenOrientation="portrait"
android:exported="false" />
<activity
android:name=".presentation.mypage.TransactionHistoryActivity"
android:screenOrientation="portrait"
android:exported="false" />
<activity
android:name=".presentation.mypage.SavedHoneyTipActivity"
android:screenOrientation="portrait"
android:exported="false" />
<activity
android:name=".presentation.mypage.MyHoneyTipActivity"
android:screenOrientation="portrait"
android:exported="false" />
<activity
android:name=".presentation.MainActivity"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,6 @@ class ChooseMainInterestDialogFragment(private val btnClickListener: (List<Strin

override fun initView() {
with(binding) {
noInterestChip.setOnClickListener {
removeAllInterest()
}
houseworkChip.setOnClickListener {
changeInterest(houseworkChip)
}
Expand All @@ -44,9 +41,6 @@ class ChooseMainInterestDialogFragment(private val btnClickListener: (List<Strin

private fun changeInterest(chip: Chip) {
Log.d("chip", chip.text.toString())
if (binding.noInterestChip.tag == YES_INTERESTING) {
removeInterest(binding.noInterestChip)
}
if (chip.tag == NOT_INTERESTING) {
addInterest(chip)
} else {
Expand All @@ -55,22 +49,6 @@ class ChooseMainInterestDialogFragment(private val btnClickListener: (List<Strin
checkInterest()
}

private fun removeAllInterest() {
with(binding) {
if (noInterestChip.tag == NOT_INTERESTING) {
removeInterest(houseworkChip)
removeInterest(cookingChip)
removeInterest(safeLifeChip)
removeInterest(fraudChip)
removeInterest(welfarePolicyChip)
addInterest(noInterestChip)
} else {
removeInterest(noInterestChip)
}
}
checkInterest()
}

private fun addInterest(chip: Chip) {
chip.tag = YES_INTERESTING
chip.setChipBackgroundColorResource(R.color.yellow)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
package com.umc.ttoklip.presentation.mypage

import androidx.core.view.isGone
import com.umc.ttoklip.R
import com.umc.ttoklip.databinding.ActivityCustomerServiceCenterBinding
import com.umc.ttoklip.presentation.base.BaseActivity
import com.umc.ttoklip.presentation.mypage.dialog.OneOnOneInquiriesDialog
import dagger.hilt.android.AndroidEntryPoint

@AndroidEntryPoint
class CustomerServiceCenterActivity :
BaseActivity<ActivityCustomerServiceCenterBinding>(R.layout.activity_customer_service_center) {
override fun initView() {
binding.customerServiceCenterBackBtn.setOnClickListener {
onBackPressedDispatcher.onBackPressed()
}
binding.faqSub1Btn.setOnClickListener {
if (binding.faqSub1Content.isGone) {
binding.faqSub1Btn.setImageResource(R.drawable.ic_arrow_up_24)
} else {
binding.faqSub1Btn.setImageResource(R.drawable.ic_arrow_down_24)
}
binding.faqSub1Content.isGone = binding.faqSub1Content.isGone.not()
}
binding.faqSub2Btn.setOnClickListener {
if (binding.faqSub2Content.isGone) {
binding.faqSub2Btn.setImageResource(R.drawable.ic_arrow_up_24)
} else {
binding.faqSub2Btn.setImageResource(R.drawable.ic_arrow_down_24)
}
binding.faqSub2Content.isGone = binding.faqSub2Content.isGone.not()
}
binding.oneOnOneInquriesBtn.setOnClickListener {
val dialog = OneOnOneInquiriesDialog()
dialog.show(supportFragmentManager, dialog.tag)
}
}

override fun initObserver() = Unit
}
Loading

0 comments on commit 7cadcbb

Please sign in to comment.