Экран логов открываеться ура ура
This commit is contained in:
parent
9d3708a95c
commit
eb690b6908
@ -1,6 +1,7 @@
|
||||
package ru.myitschool.work.ui.profile
|
||||
|
||||
import android.os.Bundle
|
||||
import android.util.Log
|
||||
import android.view.View
|
||||
import androidx.fragment.app.Fragment
|
||||
import androidx.fragment.app.viewModels
|
||||
@ -74,8 +75,9 @@ class ProfileFragment : Fragment(R.layout.fragment_profile) {
|
||||
popUpTo<ProfileDestination> { inclusive = true }
|
||||
}
|
||||
}
|
||||
|
||||
is ProfileViewModel.Action.OpenLog -> {
|
||||
findNavController().navigate(LoginDestination) {
|
||||
findNavController().navigate(EntryListDestination) {
|
||||
popUpTo<EntryListDestination> { inclusive = true }
|
||||
}
|
||||
}
|
||||
@ -86,6 +88,7 @@ class ProfileFragment : Fragment(R.layout.fragment_profile) {
|
||||
navigate(QrScanDestination)
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -93,6 +96,7 @@ class ProfileFragment : Fragment(R.layout.fragment_profile) {
|
||||
private fun initCallback() {
|
||||
binding.logout.setOnClickListener { viewModel.clickLogout() }
|
||||
binding.scan.setOnClickListener { viewModel.clickScan() }
|
||||
binding.entryList.setOnClickListener{ viewModel.clickLog()}
|
||||
}
|
||||
|
||||
override fun onDestroyView() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user