Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx
/
dj-scrm-wx-work-main
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 6d08ea3b
authored
Feb 24, 2022
by
李伟康
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
commit
1 parent
951ea3c9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
1 deletions
src/store/modules/app.js
src/store/modules/app.js
View file @
6d08ea3
...
@@ -69,7 +69,7 @@ const actions = {
...
@@ -69,7 +69,7 @@ const actions = {
login
({
dispatch
},
CORPID
)
{
login
({
dispatch
},
CORPID
)
{
let
[
redirectUrl
]
=
window
.
location
.
href
.
split
(
'?'
)
let
[
redirectUrl
]
=
window
.
location
.
href
.
split
(
'?'
)
const
code
=
getParams
(
'code'
)
const
code
=
getParams
(
'code'
)
if
(
CORPID
)
util
.
setLocalStorage
(
'dj_scrm_corpId'
,
{
corpId
:
CORPID
})
if
(
CORPID
)
util
.
setLocalStorage
(
'dj_scrm_corpId'
,
{
corpId
:
CORPID
})
if
(
code
)
{
if
(
code
)
{
const
{
corpId
}
=
util
.
getLocalStorage
(
'dj_scrm_corpId'
)
const
{
corpId
}
=
util
.
getLocalStorage
(
'dj_scrm_corpId'
)
ssoApi
ssoApi
...
@@ -140,14 +140,26 @@ const actions = {
...
@@ -140,14 +140,26 @@ const actions = {
navigation
({
dispatch
},
to
)
{
navigation
({
dispatch
},
to
)
{
let
{
redirect_uri
,
corpId
}
=
getParams
()
let
{
redirect_uri
,
corpId
}
=
getParams
()
let
userInfo
=
util
.
getLocalStorage
(
'dj_scrm_userInfo'
)
let
userInfo
=
util
.
getLocalStorage
(
'dj_scrm_userInfo'
)
let
loginList
=
util
.
getLocalStorage
(
'dj_scrm_accountList'
)
if
(
redirect_uri
)
util
.
setLocalStorage
(
'dj_scrm_redirect_uri'
,
redirect_uri
)
if
(
redirect_uri
)
util
.
setLocalStorage
(
'dj_scrm_redirect_uri'
,
redirect_uri
)
let
dj_scrm
=
util
.
getLocalStorage
(
'dj_scrm_corpId'
)
let
dj_scrm
=
util
.
getLocalStorage
(
'dj_scrm_corpId'
)
if
(
!
state
.
testView
)
state
.
testView
=
`
${
JSON
.
stringify
(
userInfo
)}
`
if
(
dj_scrm
&&
userInfo
)
{
if
(
dj_scrm
&&
userInfo
)
{
if
(
dj_scrm
.
corpId
!=
userInfo
.
entmicroId
)
{
if
(
dj_scrm
.
corpId
!=
userInfo
.
entmicroId
)
{
util
.
showLoading
()
util
.
showLoading
()
removeStoreage
()
removeStoreage
()
}
}
}
}
try
{
if
(
loginList
&&
dj_scrm
)
{
loginList
.
length
&&
loginList
.
map
(
e
=>
{
if
(
e
.
entmicroId
!=
dj_scrm
.
corpId
)
throw
false
})
}
}
catch
(
error
)
{
util
.
showLoading
()
removeStoreage
()
}
login
({
login
({
dispatch
,
dispatch
,
to
to
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment