Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
dc-common
Overview
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
jianshuqin
dc-common
Commits
e351f2c0
Commit
e351f2c0
authored
Mar 15, 2019
by
wutong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
CD/CI
parent
ee55a21a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
51 deletions
+0
-51
index.html
data-nginx/index.html
+0
-51
No files found.
data-nginx/index.html
View file @
e351f2c0
...
...
@@ -17,57 +17,6 @@
$
.
ajaxSetup
({
async
:
false
});
$
(
document
).
ready
(
function
()
{
var
locationUrl
=
'http://'
+
document
.
domain
+
'/index.html?md=index.md'
var
cookie
=
$
.
cookie
(
'token'
);
if
(
cookie
&&
cookie
!=
'null'
)
{
return
;
}
var
token
=
getParam
(
'token'
);
if
(
token
)
{
$
.
ajax
({
url
:
'http://sso.bailuntec.com/GetTokenValidation'
,
headers
:
{
Authorization
:
token
},
type
:
"get"
,
beforeSend
:
function
(
xhr
)
{
xhr
.
setRequestHeader
(
'Authorization'
,
token
);
},
success
:
function
()
{
$
.
cookie
(
'token'
,
token
,
{
expires
:
1
});
window
.
location
.
replace
(
locationUrl
);
},
error
:
function
(
error
)
{
console
.
log
(
error
);
window
.
location
.
replace
(
'http://sso.bailuntec.com/?returnUrl=http://'
+
document
.
domain
);
}
});
}
else
{
$
.
cookie
(
'token'
,
token
,
{
expires
:
1
});
window
.
location
.
replace
(
'http://sso.bailuntec.com/?returnUrl=http://'
+
document
.
domain
);
}
});
/**
* 获取指定的URL参数值
* URL:http://www.quwan.com/index?name=tyler
* 参数:paramName URL参数
* 调用方法:getParam("name")
* 返回值:tyler
*/
function
getParam
(
paramName
)
{
paramValue
=
""
,
isFound
=
!
1
;
if
(
this
.
location
.
search
.
indexOf
(
"?"
)
==
0
&&
this
.
location
.
search
.
indexOf
(
"="
)
>
1
)
{
arrSource
=
unescape
(
this
.
location
.
search
).
substring
(
1
,
this
.
location
.
search
.
length
).
split
(
"&"
),
i
=
0
;
while
(
i
<
arrSource
.
length
&&
!
isFound
)
arrSource
[
i
].
indexOf
(
"="
)
>
0
&&
arrSource
[
i
].
split
(
"="
)[
0
].
toLowerCase
()
==
paramName
.
toLowerCase
()
&&
(
paramValue
=
arrSource
[
i
].
split
(
"="
)[
1
],
isFound
=
!
0
),
i
++
}
return
paramValue
==
""
&&
(
paramValue
=
null
),
paramValue
}
</script>
</head>
...
...
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