From 11f68b51c388d6c2ecb61ad29c66a7fb82f47a17 Mon Sep 17 00:00:00 2001 From: dkyuuum Date: Tue, 20 Feb 2024 20:35:59 +0900 Subject: [PATCH] =?UTF-8?q?Fix:=20=EB=A1=9C=EA=B7=B8=EC=9D=B8=20=ED=85=8D?= =?UTF-8?q?=EC=8A=A4=ED=8A=B8=20=EB=B2=84=EA=B7=B8=20=EC=88=98=EC=A0=95=20?= =?UTF-8?q?#1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../umc/com/mobile/project/ui/login/LoginActivity.kt | 2 +- .../project/ui/login/viewmodel/LoginViewModel.kt | 10 ++++++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/app/src/main/java/umc/com/mobile/project/ui/login/LoginActivity.kt b/app/src/main/java/umc/com/mobile/project/ui/login/LoginActivity.kt index 5aaa810..11165aa 100644 --- a/app/src/main/java/umc/com/mobile/project/ui/login/LoginActivity.kt +++ b/app/src/main/java/umc/com/mobile/project/ui/login/LoginActivity.kt @@ -55,7 +55,7 @@ class LoginActivity : AppCompatActivity() { imm.hideSoftInputFromWindow(binding.etPassword.windowToken, 0) // 로그인 버튼 클릭 - binding.btnLogin.performClick() +// binding.btnLogin.performClick() return@setOnEditorActionListener true } false diff --git a/app/src/main/java/umc/com/mobile/project/ui/login/viewmodel/LoginViewModel.kt b/app/src/main/java/umc/com/mobile/project/ui/login/viewmodel/LoginViewModel.kt index 76fd26e..ea2f725 100644 --- a/app/src/main/java/umc/com/mobile/project/ui/login/viewmodel/LoginViewModel.kt +++ b/app/src/main/java/umc/com/mobile/project/ui/login/viewmodel/LoginViewModel.kt @@ -37,7 +37,7 @@ class LoginViewModel : ViewModel() { val loginStatus: LiveData get() = _loginStatus - // 추가: 로그인 성공 여부 LiveData + // 로그인 성공 여부 LiveData private val _loginSuccess: MutableLiveData = MutableLiveData() val loginSuccess: LiveData get() = _loginSuccess @@ -53,6 +53,7 @@ class LoginViewModel : ViewModel() { } init { +// _loginStatus.value = false _loginStatus.postValue(false) } @@ -77,8 +78,9 @@ class LoginViewModel : ViewModel() { _loginResult.postValue(response.body()) _loginSuccess.postValue(false) - Log.d("cookies", "$cookies") - Log.d("Login", "${response.body()}") +// Log.d("cookies", "$cookies") +// Log.d("Login", "${_loginResult.value}") +// Log.d("Login success", "${response.body()}") } else { _loginResult.postValue( LoginResponse( @@ -91,7 +93,7 @@ class LoginViewModel : ViewModel() { _loginSuccess.postValue(true) _loginStatus.postValue(true) - Log.e("Login", "정보 틀림: $loginResult") +// Log.e("Login", "정보 틀림: ${_loginResult.value}") } }