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
bf7dc656
Commit
bf7dc656
authored
Dec 31, 2020
by
YKai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:一键登录代码更新
parent
fbcba731
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
4 deletions
+13
-4
OneKeyLoginHelp.kt
m-user/src/main/java/com/yidianling/user/ui/login/OneKeyLoginHelp.kt
+13
-4
No files found.
m-user/src/main/java/com/yidianling/user/ui/login/OneKeyLoginHelp.kt
View file @
bf7dc656
...
@@ -29,22 +29,31 @@ class OneKeyLoginHelp {
...
@@ -29,22 +29,31 @@ class OneKeyLoginHelp {
private
const
val
YDL_EXPERT_APP_KEY
=
"i4Y/PVRAz4P/aqajQF7SOd3JUIKEsJbRurH04azLyX6N2upi292OrLHECRmtTVAqY24HFjwUjW1QjRwJA9aFbNzl3zl7L5DEDBZ4+QSU28vq34HccmAjAeUCC7qCHbN7QLVZqhVpuYUCMZ5fp2NdhANJl/741wHccdPk/Un5c4larDNuv1KEo2OZOds2J1WFiBx7giWtzli4NwMq9x+9sb0aXPZZQ9C9Kr8T/0+/ccYdotwFm7XWenNs/G3Jy1HHVqqOCDecKPbyXR+cV0jBUisSjv+SEUTfpcc3iUGH5OjZyQ6OfaLkdjATsr5K9oVP"
private
const
val
YDL_EXPERT_APP_KEY
=
"i4Y/PVRAz4P/aqajQF7SOd3JUIKEsJbRurH04azLyX6N2upi292OrLHECRmtTVAqY24HFjwUjW1QjRwJA9aFbNzl3zl7L5DEDBZ4+QSU28vq34HccmAjAeUCC7qCHbN7QLVZqhVpuYUCMZ5fp2NdhANJl/741wHccdPk/Un5c4larDNuv1KEo2OZOds2J1WFiBx7giWtzli4NwMq9x+9sb0aXPZZQ9C9Kr8T/0+/ccYdotwFm7XWenNs/G3Jy1HHVqqOCDecKPbyXR+cV0jBUisSjv+SEUTfpcc3iUGH5OjZyQ6OfaLkdjATsr5K9oVP"
const
val
YDL_USER_APP
=
1
const
val
YDL_USER_APP
=
1
const
val
YDL_EXPERT_APP
=
2
const
val
YDL_EXPERT_APP
=
2
const
val
PHONE_CHECK
=
1
// 本机号码验证
const
val
ONE_KEY_LOGIN
=
2
// 一键登录
}
}
constructor
(
activity
:
BaseActivity
,
Authtype
:
Int
)
{
/**
* 构造方法
*
* @param activity
* @param authType 1表示用户端一键登录 2表示
* @param loginType 1本机号码校验 2一键登录
*/
constructor
(
activity
:
BaseActivity
,
authType
:
Int
,
loginType
:
Int
)
{
mActivity
=
activity
mActivity
=
activity
mPhoneNumberAuthHelper
=
PhoneNumberAuthHelper
.
getInstance
(
activity
,
mTokenListener
)
mPhoneNumberAuthHelper
=
PhoneNumberAuthHelper
.
getInstance
(
activity
,
mTokenListener
)
mPhoneNumberAuthHelper
?.
let
{
mPhoneNumberAuthHelper
?.
let
{
// APP是否处于调试状态,使⽤ getReporter.setLoggerEnable(true) 可以关闭此项检测
// APP是否处于调试状态,使⽤ getReporter.setLoggerEnable(true) 可以关闭此项检测
it
.
reporter
.
setLoggerEnable
(
true
)
it
.
reporter
.
setLoggerEnable
(
true
)
// 设置密钥
// 设置密钥
if
(
Autht
ype
==
YDL_USER_APP
){
if
(
authT
ype
==
YDL_USER_APP
){
it
.
setAuthSDKInfo
(
YDL_USER_APP_KEY
)
it
.
setAuthSDKInfo
(
YDL_USER_APP_KEY
)
}
else
if
(
Autht
ype
==
YDL_EXPERT_APP
){
}
else
if
(
authT
ype
==
YDL_EXPERT_APP
){
it
.
setAuthSDKInfo
(
YDL_EXPERT_APP_KEY
)
it
.
setAuthSDKInfo
(
YDL_EXPERT_APP_KEY
)
}
}
// 检查认证环境
// 检查认证环境
it
.
checkEnvAvailable
(
2
)
// type 1:本机号码校验 2: ⼀键登录
it
.
checkEnvAvailable
(
loginType
)
// type 1:本机号码校验 2: ⼀键登录
}
}
}
}
...
...
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