Commit 6aab85d4 by YKai

feat:一键登录代码优化

parent 72735bd1
......@@ -361,13 +361,13 @@ object OneKeyLoginHelp {
}
}
ResultCode.CODE_SUCCESS -> { // 获取token成功
val param = PhoneLoginAutoParam(tokenRet.token, JPushUtils.getRegistrationID(),2,2,"",
RxAppTool.getAppVersionName(BaseApp.Companion.getApp()))
val param = PhoneLoginAutoParam(tokenRet.token, JPushUtils.getRegistrationID(),2,2,"", RxAppTool.getAppVersionName(BaseApp.Companion.getApp()))
LoginApiRequestUtil.autoLogin(param)
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread())
.subscribe({
if (it.code == 200) {
ToastUtil.toastShort("登录成功")
saveUserData(it.data)
if (it.data.firstLogin == 1) {//第一次登录:是注册
StatusUtils.isFirstLogin = true
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment