Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cash-loan-flow-boss
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
胡慧
cash-loan-flow-boss
Commits
ae1d7f45
Commit
ae1d7f45
authored
Aug 21, 2019
by
WeiWei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加JSESSIONID写入
parent
da3d0886
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
0 deletions
+11
-0
LogService.java
...antgroup/cashloanflowboss/api/log/service/LogService.java
+11
-0
No files found.
src/main/java/cn/quantgroup/cashloanflowboss/api/log/service/LogService.java
View file @
ae1d7f45
...
@@ -13,7 +13,9 @@ import lombok.extern.slf4j.Slf4j;
...
@@ -13,7 +13,9 @@ import lombok.extern.slf4j.Slf4j;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
javax.servlet.http.Cookie
;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletResponse
;
import
javax.servlet.http.HttpSession
;
import
javax.servlet.http.HttpSession
;
/**
/**
...
@@ -29,6 +31,9 @@ public class LogService {
...
@@ -29,6 +31,9 @@ public class LogService {
@Autowired
@Autowired
private
HttpServletRequest
request
;
private
HttpServletRequest
request
;
@Autowired
private
HttpServletResponse
response
;
/**
/**
* 登入
* 登入
*
*
...
@@ -61,6 +66,12 @@ public class LogService {
...
@@ -61,6 +66,12 @@ public class LogService {
session
.
setAttribute
(
ApplicationDictionary
.
PRINCIPAL
,
JSONTools
.
serialize
(
principal
));
session
.
setAttribute
(
ApplicationDictionary
.
PRINCIPAL
,
JSONTools
.
serialize
(
principal
));
Cookie
cookie
=
new
Cookie
(
"JSESSIONID"
,
session
.
getId
());
cookie
.
setDomain
(
".vinceruan.info"
);
cookie
.
setPath
(
"/"
);
this
.
response
.
addCookie
(
cookie
);
return
true
;
return
true
;
}
}
...
...
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