Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
J
jd-activity
Project
Project
Details
Activity
Releases
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
曾水平
jd-activity
Commits
e7dadea9
Commit
e7dadea9
authored
Nov 17, 2021
by
郝增润
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
兼容微信端
parent
a5eba71a
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
393 additions
and
3 deletions
+393
-3
Open2DuibaController.java
...com/duiba/jdactivity/controller/Open2DuibaController.java
+5
-2
TaobaoController.java
.../cn/com/duiba/jdactivity/controller/TaobaoController.java
+387
-0
application.properties
src/main/resources/application.properties
+1
-1
No files found.
src/main/java/cn/com/duiba/jdactivity/controller/Open2DuibaController.java
View file @
e7dadea9
...
@@ -180,12 +180,10 @@ public class Open2DuibaController {
...
@@ -180,12 +180,10 @@ public class Open2DuibaController {
try
{
try
{
LOGGER
.
info
(
"autologin,autologinParam={}"
,
JSON
.
toJSONString
(
autologinParam
));
LOGGER
.
info
(
"autologin,autologinParam={}"
,
JSON
.
toJSONString
(
autologinParam
));
String
token
=
autologinParam
.
getToken
();
String
token
=
autologinParam
.
getToken
();
// String source = JdTokenSourceEnum.JD.getSource();
String
source
=
Optional
.
ofNullable
(
autologinParam
.
getSource
()).
orElse
(
JdTokenSourceEnum
.
JD
.
getSource
());
String
source
=
Optional
.
ofNullable
(
autologinParam
.
getSource
()).
orElse
(
JdTokenSourceEnum
.
JD
.
getSource
());
LOGGER
.
info
(
"source,source={}"
,
source
);
LOGGER
.
info
(
"source,source={}"
,
source
);
String
redirectUrl
=
autologinParam
.
getRedirectUrl
();
String
redirectUrl
=
autologinParam
.
getRedirectUrl
();
String
env
=
autologinParam
.
getEnv
();
String
env
=
autologinParam
.
getEnv
();
Long
venderId
=
autologinParam
.
getVenderId
();
Long
venderId
=
autologinParam
.
getVenderId
();
Long
shopId
=
autologinParam
.
getShopId
();
Long
shopId
=
autologinParam
.
getShopId
();
if
(
venderId
==
null
&&
shopId
==
null
)
{
if
(
venderId
==
null
&&
shopId
==
null
)
{
...
@@ -236,6 +234,11 @@ public class Open2DuibaController {
...
@@ -236,6 +234,11 @@ public class Open2DuibaController {
* 生成免登url
* 生成免登url
*/
*/
private
String
autologin
(
DuibaAppEnum
duibaApp
,
String
uid
,
String
nickName
,
String
avatar
,
String
redirectUrl
,
String
env
,
String
credits
)
{
private
String
autologin
(
DuibaAppEnum
duibaApp
,
String
uid
,
String
nickName
,
String
avatar
,
String
redirectUrl
,
String
env
,
String
credits
)
{
if
(
env
.
equals
(
"taobao"
))
{
return
redirectUrl
+
"&avatar="
+
avatar
+
"&nickname="
+
nickName
+
"&uid="
+
uid
;
}
CreditTool
tool
=
new
CreditTool
(
duibaApp
.
getAppKey
(),
duibaApp
.
getAppSecret
());
CreditTool
tool
=
new
CreditTool
(
duibaApp
.
getAppKey
(),
duibaApp
.
getAppSecret
());
Map
<
String
,
String
>
params
=
new
HashMap
<>();
Map
<
String
,
String
>
params
=
new
HashMap
<>();
...
...
src/main/java/cn/com/duiba/jdactivity/controller/TaobaoController.java
0 → 100644
View file @
e7dadea9
This diff is collapsed.
Click to expand it.
src/main/resources/application.properties
View file @
e7dadea9
spring.application.name
=
jd-activity
spring.application.name
=
jd-activity
spring.profiles.active
=
prod
spring.profiles.active
=
dev
# 先排除一些autoconfigure
# 先排除一些autoconfigure
spring.autoconfigure.exclude
=
spring.autoconfigure.exclude
=
# tomcat
# tomcat
...
...
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