Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
Sobot_module_Dev
Project
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
sobot_android
Sobot_module_Dev
Commits
0bc403d0
Commit
0bc403d0
authored
Dec 21, 2023
by
zhengnw@sobot.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
widget 有电销功能也可以获取accesstoken
parent
eb724834
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
7 deletions
+8
-7
build.gradle
sobot_common/build.gradle
+3
-3
sobot-common-publish-mavencentral.gradle
sobot_common/sobot-common-publish-mavencentral.gradle
+1
-1
SobotLoginTools.java
...src/main/java/com/sobot/common/login/SobotLoginTools.java
+4
-3
No files found.
sobot_common/build.gradle
View file @
0bc403d0
...
@@ -11,7 +11,7 @@ android {
...
@@ -11,7 +11,7 @@ android {
//这里就是打jar包
//这里就是打jar包
task
makeJar
(
type:
Copy
)
{
task
makeJar
(
type:
Copy
)
{
//删除旧的jar包
//删除旧的jar包
delete
'build/libs/sobot_common_1.
4.9
.jar'
delete
'build/libs/sobot_common_1.
5.0
.jar'
//原地址
//原地址
from
(
'build/intermediates/packaged-classes/release/'
)
from
(
'build/intermediates/packaged-classes/release/'
)
//导出jar包的地址
//导出jar包的地址
...
@@ -19,7 +19,7 @@ android {
...
@@ -19,7 +19,7 @@ android {
//包含的jar包
//包含的jar包
include
(
'classes.jar'
)
include
(
'classes.jar'
)
//重命名jar包为mysdk
//重命名jar包为mysdk
rename
(
'classes.jar'
,
'sobot_common_1.
4.9
.jar'
)
rename
(
'classes.jar'
,
'sobot_common_1.
5.0
.jar'
)
}
}
makeJar
.
dependsOn
(
build
)
makeJar
.
dependsOn
(
build
)
}
}
...
@@ -35,7 +35,7 @@ dependencies {
...
@@ -35,7 +35,7 @@ dependencies {
api
'com.sobot.library:utils:1.1.3'
api
'com.sobot.library:utils:1.1.3'
api
'com.sobot.library:picture_x:1.1.5'
api
'com.sobot.library:picture_x:1.1.5'
api
'com.sobot.library:net:1.2.
0
'
api
'com.sobot.library:net:1.2.
2
'
api
'com.sobot.library:gson:1.1.1'
api
'com.sobot.library:gson:1.1.1'
}
}
...
...
sobot_common/sobot-common-publish-mavencentral.gradle
View file @
0bc403d0
...
@@ -12,7 +12,7 @@ task androidSourcesJar(type: Jar) {
...
@@ -12,7 +12,7 @@ task androidSourcesJar(type: Jar) {
ext
{
ext
{
PUBLISH_GROUP_ID
=
"com.sobot.library"
//项目包名
PUBLISH_GROUP_ID
=
"com.sobot.library"
//项目包名
PUBLISH_ARTIFACT_ID
=
'sobotcommon_x'
//项目名
PUBLISH_ARTIFACT_ID
=
'sobotcommon_x'
//项目名
PUBLISH_VERSION
=
'1.
4.9
'
//版本号
PUBLISH_VERSION
=
'1.
5.0
'
//版本号
}
}
...
...
sobot_common/src/main/java/com/sobot/common/login/SobotLoginTools.java
View file @
0bc403d0
...
@@ -10,6 +10,7 @@ import com.sobot.common.login.model.LoginUserEntity;
...
@@ -10,6 +10,7 @@ import com.sobot.common.login.model.LoginUserEntity;
import
com.sobot.common.login.model.ServiceFunctionVoModel
;
import
com.sobot.common.login.model.ServiceFunctionVoModel
;
import
com.sobot.common.login.model.SobotCallBaseCode
;
import
com.sobot.common.login.model.SobotCallBaseCode
;
import
com.sobot.common.login.model.SobotServiceInfoModel
;
import
com.sobot.common.login.model.SobotServiceInfoModel
;
import
com.sobot.common.login.permission.SobotPermissionManager
;
import
com.sobot.gson.SobotGsonUtil
;
import
com.sobot.gson.SobotGsonUtil
;
import
com.sobot.network.apiUtils.SobotBaseCode
;
import
com.sobot.network.apiUtils.SobotBaseCode
;
import
com.sobot.network.apiUtils.SobotHttpUtils
;
import
com.sobot.network.apiUtils.SobotHttpUtils
;
...
@@ -143,7 +144,7 @@ public class SobotLoginTools {
...
@@ -143,7 +144,7 @@ public class SobotLoginTools {
if
(
code
==
SobotResultCode
.
CODE_SUCCEEDED
)
{
if
(
code
==
SobotResultCode
.
CODE_SUCCEEDED
)
{
SobotServiceInfoModel
serviceInfoModel
=
(
SobotServiceInfoModel
)
obj
;
SobotServiceInfoModel
serviceInfoModel
=
(
SobotServiceInfoModel
)
obj
;
if
(
serviceInfoModel
!=
null
)
{
if
(
serviceInfoModel
!=
null
)
{
if
(
serviceInfoModel
.
getCallV6Flag
()
==
1
&&
!
SobotStringUtils
.
isEmpty
(
openApiHost
))
{
if
(
(
serviceInfoModel
.
getCallV6Flag
()
==
1
||
SobotPermissionManager
.
isHasNewPermission
(
SobotPermissionManager
.
SCC
))
&&
!
SobotStringUtils
.
isEmpty
(
openApiHost
))
{
if
(
userEntity
!=
null
&&
!
SobotStringUtils
.
isEmpty
(
userEntity
.
getToken
()))
{
if
(
userEntity
!=
null
&&
!
SobotStringUtils
.
isEmpty
(
userEntity
.
getToken
()))
{
//如果是v6呼叫
//如果是v6呼叫
String
tempHost
=
openApiHost
;
String
tempHost
=
openApiHost
;
...
@@ -221,7 +222,7 @@ public class SobotLoginTools {
...
@@ -221,7 +222,7 @@ public class SobotLoginTools {
if
(
code
==
SobotResultCode
.
CODE_SUCCEEDED
)
{
if
(
code
==
SobotResultCode
.
CODE_SUCCEEDED
)
{
SobotServiceInfoModel
serviceInfoModel
=
(
SobotServiceInfoModel
)
obj
;
SobotServiceInfoModel
serviceInfoModel
=
(
SobotServiceInfoModel
)
obj
;
if
(
serviceInfoModel
!=
null
)
{
if
(
serviceInfoModel
!=
null
)
{
if
(
serviceInfoModel
.
getCallV6Flag
()
==
1
&&
!
SobotStringUtils
.
isEmpty
(
openApiHost
))
{
if
(
(
serviceInfoModel
.
getCallV6Flag
()
==
1
||
SobotPermissionManager
.
isHasNewPermission
(
SobotPermissionManager
.
SCC
))
&&
!
SobotStringUtils
.
isEmpty
(
openApiHost
))
{
if
(
userEntity
!=
null
&&
!
SobotStringUtils
.
isEmpty
(
userEntity
.
getToken
()))
{
if
(
userEntity
!=
null
&&
!
SobotStringUtils
.
isEmpty
(
userEntity
.
getToken
()))
{
//如果是v6呼叫
//如果是v6呼叫
String
tempHost
=
openApiHost
;
String
tempHost
=
openApiHost
;
...
@@ -284,7 +285,7 @@ public class SobotLoginTools {
...
@@ -284,7 +285,7 @@ public class SobotLoginTools {
if
(
code
==
SobotResultCode
.
CODE_SUCCEEDED
)
{
if
(
code
==
SobotResultCode
.
CODE_SUCCEEDED
)
{
SobotServiceInfoModel
serviceInfoModel
=
(
SobotServiceInfoModel
)
obj
;
SobotServiceInfoModel
serviceInfoModel
=
(
SobotServiceInfoModel
)
obj
;
if
(
serviceInfoModel
!=
null
)
{
if
(
serviceInfoModel
!=
null
)
{
if
(
serviceInfoModel
.
getCallV6Flag
()
==
1
)
{
if
(
(
serviceInfoModel
.
getCallV6Flag
()
==
1
||
SobotPermissionManager
.
isHasNewPermission
(
SobotPermissionManager
.
SCC
))
)
{
if
(
userEntity
!=
null
&&
!
SobotStringUtils
.
isEmpty
(
userEntity
.
getToken
()))
{
if
(
userEntity
!=
null
&&
!
SobotStringUtils
.
isEmpty
(
userEntity
.
getToken
()))
{
//如果是v6呼叫
//如果是v6呼叫
String
tempHost
=
host
;
String
tempHost
=
host
;
...
...
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