Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
T
traffic-front
Project
Project
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangxiaoming
traffic-front
Commits
302b4089
Commit
302b4089
authored
Nov 29, 2018
by
eddie.woo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
modify
parent
cc888f21
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
IndexController.java
...java/pwc/taxtech/atms/web/controller/IndexController.java
+8
-2
No files found.
atms-web/src/main/java/pwc/taxtech/atms/web/controller/IndexController.java
View file @
302b4089
...
...
@@ -30,12 +30,18 @@ public class IndexController {
public
String
login
(
@CookieValue
(
value
=
"AtmsApiToken"
,
required
=
false
)
String
atmsApiToken
,
@CookieValue
(
value
=
"LtpaToken"
,
required
=
false
)
String
ltpaToken
,
HttpServletRequest
request
,
HttpServletResponse
response
)
throws
IOException
,
ServletException
{
try
{
System
.
out
.
println
(
"------ "
+
JSON
.
toJSONString
(
request
.
getCookies
())
+
" --------"
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
if
(
StringUtils
.
hasText
(
atmsApiToken
))
{
return
"index"
;
}
else
if
(
StringUtils
.
hasText
(
ltpaToken
))
{
String
user
=
LtpaToken
.
validate
(
ltpaToken
);
if
(
StringUtils
.
isEmpty
(
user
))
return
"redirect:Account/LogOn"
;
else
{
if
(
StringUtils
.
isEmpty
(
user
))
{
return
"redirect:Account/LogOn"
;
}
else
{
AtmsTokenDto
token
=
new
AtmsTokenDto
();
String
accessToken
=
jwtUtil
.
generateToken
(
user
,
user
,
user
);
token
.
setAccess_token
(
accessToken
);
...
...
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