Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
YDL-Component-Medical
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
杨凯
YDL-Component-Medical
Commits
e93f02a7
Commit
e93f02a7
authored
Jan 18, 2021
by
YKai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:修复绑定号验证失败问题
parent
e298457c
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
92 additions
and
121 deletions
+92
-121
config.gradle
config.gradle
+1
-1
AccountSettingActivity.java
m-user/src/main/java/com/yidianling/user/mine/AccountSettingActivity.java
+1
-49
RegisterAndLoginActivity.kt
m-user/src/main/java/com/yidianling/user/ui/login/RegisterAndLoginActivity.kt
+90
-71
No files found.
config.gradle
View file @
e93f02a7
...
...
@@ -8,7 +8,7 @@ ext {
"m-confide"
:
"0.0.48.91"
,
"m-consultant"
:
"0.0.59.40"
,
"m-fm"
:
"0.0.30.00"
,
"m-user"
:
"0.0.60.
58
"
,
"m-user"
:
"0.0.60.
60
"
,
"m-home"
:
"0.0.22.51"
,
"m-im"
:
"0.0.18.30"
,
"m-dynamic"
:
"0.0.7.13"
,
...
...
m-user/src/main/java/com/yidianling/user/mine/AccountSettingActivity.java
View file @
e93f02a7
...
...
@@ -394,54 +394,6 @@ public class AccountSettingActivity extends BaseActivity implements View.OnClick
dismissProgressDialog
();
}
});
/* UMShareAPI.get(this).doOauthVerify(this, SHARE_MEDIA.WEIXIN, new UMAuthListener() {
@Override
public void onStart(SHARE_MEDIA share_media) {
}
@SuppressLint("CheckResult")
@Override
public void onComplete(SHARE_MEDIA share_media, int i, Map<String, String> map) {
if (map == null||map.size()==0) {
return;
}
String openid = map.get("openid");
String unionid = map.get("unionid");
LogUtil.e("aaaaa"+openid+"bbbb"+unionid);
userHttp.bindWX(new BindWX(openid, unionid))
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread())
.subscribe(o -> {
dismissProgressDialog();
if(o.code == 0 ) {
UserHelper.INSTANCE.getUserInfo().getUserInfo().setBind_weixin(1);
jtv_wechat.setRightText("已绑定");
ToastUtil.toastShort("绑定成功");
}else{
ToastHelper.Companion.show(o.msg);
}
}, new ThrowableConsumer() {
@Override
public void accept(@NotNull String msg) {
dismissProgressDialog();
}
});
UMShareAPI.get(AccountSettingActivity.this).deleteOauth(AccountSettingActivity.this, SHARE_MEDIA.WEIXIN, this);
}
@Override
public void onError(SHARE_MEDIA share_media, int i, Throwable throwable) {
dismissProgressDialog();
ToastUtil.toastShort(throwable.getMessage());
}
@Override
public void onCancel(SHARE_MEDIA share_media, int i) {
dismissProgressDialog();
}
});*/
}
/**
...
...
@@ -559,7 +511,7 @@ public class AccountSettingActivity extends BaseActivity implements View.OnClick
* 绑定手机
*/
private
void
bindPhone
()
{
RegisterAndLoginActivity
.
Companion
.
start
(
this
,
true
);
RegisterAndLoginActivity
.
Companion
.
start
(
this
,
true
);
}
private
String
isNullString
(
String
str
)
{
...
...
m-user/src/main/java/com/yidianling/user/ui/login/RegisterAndLoginActivity.kt
View file @
e93f02a7
...
...
@@ -42,7 +42,6 @@ import com.yidianling.user.R
import
com.yidianling.user.StatusUtils
import
com.yidianling.user.UserHelper
import
com.yidianling.user.api.bean.UserResponseBean
import
com.yidianling.user.bean.AliAuthBean
import
com.yidianling.user.constants.UserBIConstants
import
com.yidianling.user.http.request.BindPhoneJavaParam
import
com.yidianling.user.http.request.PhoneLoginAutoParam
...
...
@@ -70,11 +69,12 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
ILoginContract
.
View
{
private
var
userPhoneNumber
:
String
?
=
null
// 是否支持号码认证
private
var
isCanAuth
:
Boolean
=
false
private
var
chcekPhoneResponeBean
:
ChcekPhoneResponeBean
?
=
null
// 手机号校验结果
private
var
is
UmengLoginState
:
Boolean
=
false
//true 通过第三方登录后绑定手机号码
private
var
is
BindPhone
:
Boolean
=
false
// 是否绑定手机号
private
var
countryCode
:
String
?
=
"0086"
//国家或地区手机区号
private
var
handler
:
Handler
?
=
null
private
var
isFromGuide
=
false
//是否来自启动页
...
...
@@ -82,13 +82,14 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
companion
object
{
private
var
BIND_PHONE
=
"bind_phone"
//用于判断时候是绑定手机号
private
var
IS_FROM_GUIDE
=
"isFromGuide"
//是否来自启动页
private
var
IS_FROM_ACCOUNT_SET
=
"isFromAccountSet"
// 是否来自设置页
var
REQUEST_CODE_COUNTRY
=
1024
fun
start
(
context
:
Context
)
{
start
(
context
,
false
)
}
/**
* 绑定手机号调用此方法启动
*
第三方登录,
绑定手机号调用此方法启动
*/
fun
start
(
context
:
Context
,
isBindPhone
:
Boolean
)
{
startFromGuide
(
context
,
isBindPhone
,
false
)
...
...
@@ -118,7 +119,7 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
}
override
fun
initDataAndEvent
()
{
is
UmengLoginStat
e
=
intent
.
getBooleanExtra
(
BIND_PHONE
,
false
)
is
BindPhon
e
=
intent
.
getBooleanExtra
(
BIND_PHONE
,
false
)
isFromGuide
=
intent
.
getBooleanExtra
(
IS_FROM_GUIDE
,
false
)
StatusUtils
.
isFromGuide
=
isFromGuide
...
...
@@ -130,7 +131,7 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
private
fun
setWindowStatusBarColor
()
{
StatusBarUtils
.
Companion
.
setWindowStatusBarColor
(
this
,
R
.
color
.
white
)
StatusBarUtils
.
Companion
.
setStatusBarLightMode
(
this
,
true
)
StatusBarUtils
.
Companion
.
setStatusBarLightMode
(
this
,
true
)
}
@SuppressLint
(
"CheckResult"
)
...
...
@@ -176,22 +177,16 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
requestPermission
()
OneKeyLoginHelp
.
checkEnvAvailable
(
PhoneNumberAuthHelper
.
SERVICE_TYPE_AUTH
)
OneKeyLoginHelp
.
setVerifyTokenResultListener
(
object
:
OneKeyLoginHelp
.
VerifyTokenResultListener
{
OneKeyLoginHelp
.
setVerifyTokenResultListener
(
object
:
OneKeyLoginHelp
.
VerifyTokenResultListener
{
override
fun
onTokenSuccess
(
result
:
String
)
{
val
tokenRet
=
TokenRet
.
fromJson
(
result
)
when
(
tokenRet
.
code
)
{
ResultCode
.
CODE_ERROR_ENV_CHECK_SUCCESS
->
{
// 终端环境支持认证
isCanAuth
=
true
ResultCode
.
CODE_ERROR_ENV_CHECK_SUCCESS
->
{
// 终端环境支持认证
isCanAuth
=
true
}
ResultCode
.
CODE_SUCCESS
->
{
// 获取token成功
val
aliAuthBean
=
AliAuthBean
()
aliAuthBean
.
accessCode
=
tokenRet
.
token
if
(
isUmengLoginState
)
{
//绑定手机号码
umengLoginBindPhone
(
aliAuthBean
.
accessCode
)
}
else
{
autoLogin
(
tokenRet
.
token
)
}
autoLogin
(
tokenRet
.
token
)
OneKeyLoginHelp
.
mPhoneNumberAuthHelper
?.
setAuthListener
(
null
)
OneKeyLoginHelp
.
mIsGetTokenSuccess
=
false
}
...
...
@@ -214,12 +209,13 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
spannableString
.
setSpan
(
object
:
ClickableSpan
()
{
override
fun
updateDrawState
(
ds
:
TextPaint
)
{
super
.
updateDrawState
(
ds
)
ds
.
color
=
ContextCompat
.
getColor
(
this
@RegisterAndLoginActivity
,
R
.
color
.
user_1da1f2trans
)
ds
.
color
=
ContextCompat
.
getColor
(
this
@RegisterAndLoginActivity
,
R
.
color
.
user_1da1f2trans
)
ds
.
isUnderlineText
=
true
//设置下划线
}
override
fun
onClick
(
widget
:
View
)
{
if
(!
is
UmengLoginStat
e
)
{
if
(!
is
BindPhon
e
)
{
H5Activity
.
start
(
this
@RegisterAndLoginActivity
,
false
)
overridePendingTransition
(
R
.
anim
.
platform_slide_in_from_bottom
,
...
...
@@ -231,12 +227,13 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
spannableString
.
setSpan
(
object
:
ClickableSpan
()
{
override
fun
updateDrawState
(
ds
:
TextPaint
)
{
super
.
updateDrawState
(
ds
)
ds
.
color
=
ContextCompat
.
getColor
(
this
@RegisterAndLoginActivity
,
R
.
color
.
user_1da1f2trans
)
ds
.
color
=
ContextCompat
.
getColor
(
this
@RegisterAndLoginActivity
,
R
.
color
.
user_1da1f2trans
)
ds
.
isUnderlineText
=
true
//设置下划线
}
override
fun
onClick
(
widget
:
View
)
{
if
(!
is
UmengLoginStat
e
)
{
if
(!
is
BindPhon
e
)
{
H5Activity
.
start
(
this
@RegisterAndLoginActivity
,
true
)
overridePendingTransition
(
R
.
anim
.
platform_slide_in_from_bottom
,
...
...
@@ -255,7 +252,7 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
setHint
()
requestFocus
()
if
(
is
UmengLoginStat
e
)
{
if
(
is
BindPhon
e
)
{
skip_bind
.
visibility
=
View
.
VISIBLE
// tv_des.text = "首次绑定即送大礼包"
// tv_des.visibility = View.GONE//"同意"
...
...
@@ -264,9 +261,9 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
login_wechat
.
visibility
=
View
.
GONE
login_qq
.
visibility
=
View
.
GONE
tv_login_title
.
text
=
"手机号绑定"
ll_next
.
text
=
"发送验证码"
ll_next
.
text
=
"发送验证码"
tv_protocol
.
visibility
=
View
.
GONE
other_login_style
.
visibility
=
View
.
GONE
other_login_style
.
visibility
=
View
.
GONE
}
...
...
@@ -284,9 +281,9 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
}
setCountryIcon
(
countryCode
)
if
(
et_phone_number
.
text
.
length
>
0
)
{
ll_next
.
isEnabled
=
true
ll_next
.
background
=
ContextCompat
.
getDrawable
(
this
,
R
.
drawable
.
bg_one_click_login
)
if
(
et_phone_number
.
text
.
length
>
0
)
{
ll_next
.
isEnabled
=
true
ll_next
.
background
=
ContextCompat
.
getDrawable
(
this
,
R
.
drawable
.
bg_one_click_login
)
}
if
(
isFromGuide
)
{
...
...
@@ -337,7 +334,14 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
*/
private
fun
setClickEvent
()
{
skip_bind
.
setOnClickListener
{
ActionCountUtils
.
count
(
uid
=
""
,
partId
=
UserBIConstants
.
PART_ID_LOGIN_MAIN
,
position
=
UserBIConstants
.
POSITION_LOOK_AROUND_CLICK
,
url
=
"无url"
,
api
=
"无api"
,
sign1
=
""
)
ActionCountUtils
.
count
(
uid
=
""
,
partId
=
UserBIConstants
.
PART_ID_LOGIN_MAIN
,
position
=
UserBIConstants
.
POSITION_LOOK_AROUND_CLICK
,
url
=
"无url"
,
api
=
"无api"
,
sign1
=
""
)
RxKeyboardTool
.
hideSoftInput
(
this
)
onBackPressed
()
}
...
...
@@ -350,13 +354,14 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
//protocol_android 1是开启默认勾选,2是关闭默认勾选,方便应用市场审核
//新逻辑:华为一直不默认勾选(上线后华为也会抽查隐私协议勾选情况),vivo审核不默认勾选,通过后默认勾选
val
privacyOnOffType
=
PlatformRamImpl
.
getInstance
().
getGlobalInfo
()
?.
info
?.
protocol_android
?:
2
val
privacyOnOffType
=
PlatformRamImpl
.
getInstance
().
getGlobalInfo
()
?.
info
?.
protocol_android
?:
2
val
channel
=
WalleChannelReader
.
getChannel
(
applicationContext
)
if
(
channel
==
"huawei"
)
{
if
(
channel
==
"huawei"
)
{
iv_select_protocol
.
setImageResource
(
R
.
drawable
.
user_login_protocol_unselected_new
)
}
else
if
(
privacyOnOffType
==
2
&&
(
channel
==
"vivo"
))
{
}
else
if
(
privacyOnOffType
==
2
&&
(
channel
==
"vivo"
))
{
iv_select_protocol
.
setImageResource
(
R
.
drawable
.
user_login_protocol_unselected_new
)
}
else
{
}
else
{
isAgreeProtocol
=
true
iv_select_protocol
.
setImageResource
(
R
.
drawable
.
user_login_protocol_selected_new
)
}
...
...
@@ -396,7 +401,7 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
return
@setOnClickListener
}
if
(
checkPhone
())
{
mPresenter
.
checkPhoneStatus
(
userPhoneNumber
!!
,
countryCode
!!
,
is
UmengLoginStat
e
)
mPresenter
.
checkPhoneStatus
(
userPhoneNumber
!!
,
countryCode
!!
,
is
BindPhon
e
)
}
}
...
...
@@ -410,12 +415,13 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
iv_del
.
visibility
=
View
.
VISIBLE
iv_del
.
isEnabled
=
true
}
if
(
it
.
toString
().
length
==
13
||(!
countryCode
?.
contains
(
"86"
)
!!
&&
et_phone_number
.
text
.
toString
().
length
>
0
)){
ll_next
.
isEnabled
=
true
ll_next
.
background
=
ContextCompat
.
getDrawable
(
this
,
R
.
drawable
.
bg_one_click_login
)
}
else
{
ll_next
.
isEnabled
=
false
ll_next
.
background
=
ContextCompat
.
getDrawable
(
this
,
R
.
drawable
.
login_password_unable_bg_24dp
)
if
(
it
.
toString
().
length
==
13
||
(!
countryCode
?.
contains
(
"86"
)
!!
&&
et_phone_number
.
text
.
toString
().
length
>
0
))
{
ll_next
.
isEnabled
=
true
ll_next
.
background
=
ContextCompat
.
getDrawable
(
this
,
R
.
drawable
.
bg_one_click_login
)
}
else
{
ll_next
.
isEnabled
=
false
ll_next
.
background
=
ContextCompat
.
getDrawable
(
this
,
R
.
drawable
.
login_password_unable_bg_24dp
)
}
}
//删除按钮
...
...
@@ -439,7 +445,10 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
if
(!
TextUtils
.
equals
(
"0086"
,
countryCode
))
{
return
!
TextUtils
.
isEmpty
(
editPhone
)
}
return
if
(
editPhone
.
length
==
11
&&
editPhone
.
startsWith
(
"1"
)&&
checkRegex
(
editPhone
.
toString
().
trim
()))
{
return
if
(
editPhone
.
length
==
11
&&
editPhone
.
startsWith
(
"1"
)
&&
checkRegex
(
editPhone
.
toString
().
trim
()
)
)
{
view_lin
.
setBackgroundColor
(
Color
.
parseColor
(
"#E8E8E8"
))
true
}
else
{
...
...
@@ -449,15 +458,17 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
false
}
}
private
fun
checkRegex
(
phone
:
String
):
Boolean
{
val
regex
=
"^1+[23456789]+\\d{9}"
private
fun
checkRegex
(
phone
:
String
):
Boolean
{
val
regex
=
"^1+[23456789]+\\d{9}"
return
phone
.
matches
(
regex
.
toRegex
())
}
/**
* 三方登录成功后绑定手机号
*/
private
fun
umengLoginBindPhone
(
accessCode
:
String
?)
{
va
r
param
=
BindPhoneJavaParam
(
va
l
param
=
BindPhoneJavaParam
(
accessCode
!!
,
countryCode
!!
,
userPhoneNumber
!!
,
...
...
@@ -483,22 +494,22 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
var
bindPhone
=
userInfo
.
bind_phone
if
(
bindPhone
!=
1
)
{
countryCode
=
userInfo
.
country_code
is
UmengLoginStat
e
=
true
is
BindPhon
e
=
true
skip_bind
.
visibility
=
View
.
VISIBLE
// tv_des.text = "首次绑定即送大礼包"
// tv_des.visibility = View.GONE
iv_select_protocol
.
visibility
=
View
.
GONE
// tv_des_first.visibility = View.VISIBLE
bind_phone_hint
.
visibility
=
View
.
VISIBLE
bind_phone_hint
.
visibility
=
View
.
VISIBLE
login_wechat
.
visibility
=
View
.
GONE
login_qq
.
visibility
=
View
.
GONE
tv_login_title
.
text
=
"绑定手机号"
tv_protocol
.
visibility
=
View
.
GONE
other_login_style
.
visibility
=
View
.
GONE
other_login_style
.
visibility
=
View
.
GONE
}
else
{
if
(
isFromGuide
)
{
LoginUtils
.
LoginSuccessOperate
(
this
)
}
else
{
}
else
{
finish
()
}
}
...
...
@@ -510,12 +521,17 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
override
fun
checkPhoneStatusSuccess
(
bean
:
ChcekPhoneResponeBean
?,
phone
:
String
)
{
//校验手机号的结果需要在本地保存,后续一键认证登录失败后跳转密码登录需要用到校验结果
if
(
bean
!=
null
)
{
chcekPhoneResponeBean
=
ChcekPhoneResponeBean
(
bean
.
hasPwd
,
bean
.
isDoctor
,
bean
.
isRegistered
)
chcekPhoneResponeBean
=
ChcekPhoneResponeBean
(
bean
.
hasPwd
,
bean
.
isDoctor
,
bean
.
isRegistered
)
}
if
(
isCanAuth
)
{
OneKeyLoginHelp
.
getVerifyToken
()
}
else
{
if
(
isBindPhone
)
{
aliAuthFailed
()
}
else
{
if
(
isCanAuth
)
{
OneKeyLoginHelp
.
getVerifyToken
()
}
else
{
aliAuthFailed
()
}
}
}
...
...
@@ -548,7 +564,7 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
userPhoneNumber
!!
,
countryCode
!!
,
VerificationCodeActivity
.
STATUS_LOGIN_BY_CODE
,
is
UmengLoginStat
e
,
is
BindPhon
e
,
false
)
}
...
...
@@ -558,9 +574,11 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
/**
* 通过阿里sdk一键认证服务登陆
*/
private
fun
autoLogin
(
token
:
String
)
{
val
param
=
PhoneLoginAutoParam
(
token
,
JPushUtils
.
getRegistrationID
(),
2
,
1
,
userPhoneNumber
!!
,
RxAppTool
.
getAppVersionName
(
BaseApp
.
Companion
.
getApp
()))
private
fun
autoLogin
(
token
:
String
)
{
val
param
=
PhoneLoginAutoParam
(
token
,
JPushUtils
.
getRegistrationID
(),
2
,
1
,
userPhoneNumber
!!
,
RxAppTool
.
getAppVersionName
(
BaseApp
.
Companion
.
getApp
())
)
mPresenter
.
autoLogin
(
param
)
}
...
...
@@ -574,13 +592,14 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
finishPrePage
()
}
/**
*菊花框
*/
override
fun
showLoading
(
state
:
Boolean
)
{
if
(
state
){
if
(
state
)
{
showProgressDialog
()
}
else
{
}
else
{
dismissProgressDialog
()
}
}
...
...
@@ -595,7 +614,7 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
handler
!!
.
postDelayed
({
if
(
isFromGuide
)
{
LoginUtils
.
LoginSuccessOperate
(
this
)
}
else
{
}
else
{
finish
()
}
},
1000
)
...
...
@@ -665,20 +684,20 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
* 根据国家个地区号设置国旗
*/
private
fun
setCountryIcon
(
code
:
String
?)
{
country_code
.
text
=
"+"
+
countryCode
?.
replace
(
"00"
,
""
)
/* when (code) {
"0086" -> iv_country_icon.setImageResource(R.drawable.user_ic_china)
"001" -> iv_country_icon.setImageResource(R.drawable.user_country_usa)
"00886" -> iv_country_icon.setImageResource(R.drawable.user_ic_china)
"0081" -> iv_country_icon.setImageResource(R.drawable.user_country_japan)
"00852" -> iv_country_icon.setImageResource(R.drawable.user_country_hk)
"0061" -> iv_country_icon.setImageResource(R.drawable.user_country_australia)
"0064" -> iv_country_icon.setImageResource(R.drawable.user_country_nz)
"0082" -> iv_country_icon.setImageResource(R.drawable.user_country_sk)
"0060" -> iv_country_icon.setImageResource(R.drawable.user_country_malaysia)
"0044" -> iv_country_icon.setImageResource(R.drawable.user_country_uk)
else -> iv_country_icon.visibility = View.VISIBLE
}*/
country_code
.
text
=
"+"
+
countryCode
?.
replace
(
"00"
,
""
)
/* when (code) {
"0086" -> iv_country_icon.setImageResource(R.drawable.user_ic_china)
"001" -> iv_country_icon.setImageResource(R.drawable.user_country_usa)
"00886" -> iv_country_icon.setImageResource(R.drawable.user_ic_china)
"0081" -> iv_country_icon.setImageResource(R.drawable.user_country_japan)
"00852" -> iv_country_icon.setImageResource(R.drawable.user_country_hk)
"0061" -> iv_country_icon.setImageResource(R.drawable.user_country_australia)
"0064" -> iv_country_icon.setImageResource(R.drawable.user_country_nz)
"0082" -> iv_country_icon.setImageResource(R.drawable.user_country_sk)
"0060" -> iv_country_icon.setImageResource(R.drawable.user_country_malaysia)
"0044" -> iv_country_icon.setImageResource(R.drawable.user_country_uk)
else -> iv_country_icon.visibility = View.VISIBLE
}*/
}
override
fun
onDestroy
()
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment