Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
apollo
Project
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
openSource
apollo
Commits
9c71307c
Commit
9c71307c
authored
Feb 24, 2018
by
乐兜
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refresh session & add admin pages entry point
parent
e5c10127
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
56 additions
and
9 deletions
+56
-9
CtripSsoHeartbeatHandler.java
...ork/apollo/portal/spi/ctrip/CtripSsoHeartbeatHandler.java
+2
-0
DefaultSsoHeartbeatHandler.java
...lo/portal/spi/defaultimpl/DefaultSsoHeartbeatHandler.java
+3
-2
app.html
apollo-portal/src/main/resources/static/app.html
+3
-2
setting.html
apollo-portal/src/main/resources/static/app/setting.html
+1
-0
cluster.html
apollo-portal/src/main/resources/static/cluster.html
+1
-0
history.html
apollo-portal/src/main/resources/static/config/history.html
+1
-0
sync.html
apollo-portal/src/main/resources/static/config/sync.html
+2
-0
default_sso_heartbeat.html
...rtal/src/main/resources/static/default_sso_heartbeat.html
+19
-0
index.html
apollo-portal/src/main/resources/static/index.html
+2
-1
directive.js
.../src/main/resources/static/scripts/directive/directive.js
+8
-3
server_config.html
apollo-portal/src/main/resources/static/server_config.html
+3
-1
user-manage.html
apollo-portal/src/main/resources/static/user-manage.html
+1
-0
nav.html
...lo-portal/src/main/resources/static/views/common/nav.html
+10
-0
No files found.
apollo-portal/src/main/java/com/ctrip/framework/apollo/portal/spi/ctrip/CtripSsoHeartbeatHandler.java
View file @
9c71307c
...
@@ -11,6 +11,7 @@ import javax.servlet.http.HttpServletResponse;
...
@@ -11,6 +11,7 @@ import javax.servlet.http.HttpServletResponse;
* @author Jason Song(song_s@ctrip.com)
* @author Jason Song(song_s@ctrip.com)
*/
*/
public
class
CtripSsoHeartbeatHandler
implements
SsoHeartbeatHandler
{
public
class
CtripSsoHeartbeatHandler
implements
SsoHeartbeatHandler
{
@Override
@Override
public
void
doHeartbeat
(
HttpServletRequest
request
,
HttpServletResponse
response
)
{
public
void
doHeartbeat
(
HttpServletRequest
request
,
HttpServletResponse
response
)
{
try
{
try
{
...
@@ -18,4 +19,5 @@ public class CtripSsoHeartbeatHandler implements SsoHeartbeatHandler {
...
@@ -18,4 +19,5 @@ public class CtripSsoHeartbeatHandler implements SsoHeartbeatHandler {
}
catch
(
IOException
e
)
{
}
catch
(
IOException
e
)
{
}
}
}
}
}
}
apollo-portal/src/main/java/com/ctrip/framework/apollo/portal/spi/defaultimpl/DefaultSsoHeartbeatHandler.java
View file @
9c71307c
...
@@ -11,12 +11,13 @@ import javax.servlet.http.HttpServletResponse;
...
@@ -11,12 +11,13 @@ import javax.servlet.http.HttpServletResponse;
* @author Jason Song(song_s@ctrip.com)
* @author Jason Song(song_s@ctrip.com)
*/
*/
public
class
DefaultSsoHeartbeatHandler
implements
SsoHeartbeatHandler
{
public
class
DefaultSsoHeartbeatHandler
implements
SsoHeartbeatHandler
{
@Override
@Override
public
void
doHeartbeat
(
HttpServletRequest
request
,
HttpServletResponse
response
)
{
public
void
doHeartbeat
(
HttpServletRequest
request
,
HttpServletResponse
response
)
{
try
{
try
{
response
.
setContentType
(
"text/plain;charset=utf-8"
);
response
.
sendRedirect
(
"default_sso_heartbeat.html"
);
response
.
getWriter
().
write
(
"default sso heartbeat handler"
);
}
catch
(
IOException
e
)
{
}
catch
(
IOException
e
)
{
}
}
}
}
}
}
apollo-portal/src/main/resources/static/app.html
View file @
9c71307c
...
@@ -119,10 +119,11 @@
...
@@ -119,10 +119,11 @@
<script
type=
"application/javascript"
src=
"scripts/services/EnvService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/EnvService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/UserService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/UserService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/
AppUtils
.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/
services/PermissionService
.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/OrganizationService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/OrganizationService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/directive/directive.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/directive/directive.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/AppController.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/AppController.js"
></script>
<script
src=
"scripts/valdr.js"
type=
"text/javascript"
></script>
<script
src=
"scripts/valdr.js"
type=
"text/javascript"
></script>
...
...
apollo-portal/src/main/resources/static/app/setting.html
View file @
9c71307c
...
@@ -189,6 +189,7 @@
...
@@ -189,6 +189,7 @@
<script
type=
"application/javascript"
src=
"../scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/PermissionService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/PermissionService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/OrganizationService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/OrganizationService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/PermissionService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/AppUtils.js"
></script>
...
...
apollo-portal/src/main/resources/static/cluster.html
View file @
9c71307c
...
@@ -131,6 +131,7 @@
...
@@ -131,6 +131,7 @@
<script
type=
"application/javascript"
src=
"scripts/services/ClusterService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/ClusterService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/directive/directive.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/directive/directive.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/PermissionService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/ClusterController.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/ClusterController.js"
></script>
...
...
apollo-portal/src/main/resources/static/config/history.html
View file @
9c71307c
...
@@ -270,6 +270,7 @@
...
@@ -270,6 +270,7 @@
<script
type=
"application/javascript"
src=
"../scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/ReleaseHistoryService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/ReleaseHistoryService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/ConfigService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/ConfigService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/PermissionService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/controller/config/ReleaseHistoryController.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/controller/config/ReleaseHistoryController.js"
></script>
...
...
apollo-portal/src/main/resources/static/config/sync.html
View file @
9c71307c
...
@@ -235,6 +235,8 @@
...
@@ -235,6 +235,8 @@
<script
type=
"application/javascript"
src=
"../scripts/services/ConfigService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/ConfigService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/UserService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/UserService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/PermissionService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/controller/config/SyncConfigController.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/controller/config/SyncConfigController.js"
></script>
...
...
apollo-portal/src/main/resources/static/default_sso_heartbeat.html
0 → 100644
View file @
9c71307c
<!DOCTYPE html>
<html
lang=
"en"
>
<head>
<meta
charset=
"UTF-8"
>
<title>
SSO Heartbeat
</title>
<script
type=
"text/javascript"
>
var
reloading
=
false
;
setInterval
(
function
()
{
if
(
reloading
)
{
return
;
}
reloading
=
true
;
location
.
reload
(
true
);
},
60000
);
</script>
</head>
<body>
</body>
</html>
apollo-portal/src/main/resources/static/index.html
View file @
9c71307c
...
@@ -81,7 +81,7 @@
...
@@ -81,7 +81,7 @@
</div>
</div>
</div>
</div>
<div
class=
"no-favorites text-center"
ng-show=
"!favorites || favorites.length == 0"
>
<div
class=
"no-favorites text-center"
ng-show=
"!favorites || favorites.length == 0"
>
<h4>
您还没有收藏过任何项目
,
在项目主页可以收藏项目哟~
</h4>
<h4>
您还没有收藏过任何项目
,
在项目主页可以收藏项目哟~
</h4>
</div>
</div>
</aside>
</aside>
...
@@ -128,6 +128,7 @@
...
@@ -128,6 +128,7 @@
<script
type=
"application/javascript"
src=
"scripts/services/UserService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/UserService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/FavoriteService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/FavoriteService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/PermissionService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/directive/directive.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/directive/directive.js"
></script>
...
...
apollo-portal/src/main/resources/static/scripts/directive/directive.js
View file @
9c71307c
/** navbar */
/** navbar */
directive_module
.
directive
(
'apollonav'
,
directive_module
.
directive
(
'apollonav'
,
function
(
$compile
,
$window
,
toastr
,
AppUtil
,
AppService
,
EnvService
,
UserService
,
CommonService
)
{
function
(
$compile
,
$window
,
toastr
,
AppUtil
,
AppService
,
EnvService
,
UserService
,
CommonService
,
PermissionService
)
{
return
{
return
{
restrict
:
'E'
,
restrict
:
'E'
,
templateUrl
:
'../../views/common/nav.html'
,
templateUrl
:
'../../views/common/nav.html'
,
...
@@ -82,7 +83,7 @@ directive_module.directive('apollonav',
...
@@ -82,7 +83,7 @@ directive_module.directive('apollonav',
}
}
//强制刷新
//强制刷新
scope
.
$apply
(
function
()
{
scope
.
$apply
(
function
()
{
scope
.
cop
yedApps
=
scope
.
copy
edApps
;
scope
.
cop
iedApps
=
scope
.
copi
edApps
;
});
});
});
});
...
@@ -97,7 +98,7 @@ directive_module.directive('apollonav',
...
@@ -97,7 +98,7 @@ directive_module.directive('apollonav',
});
});
function
clearAppsSelectedStatus
()
{
function
clearAppsSelectedStatus
()
{
scope
.
cop
y
edApps
.
forEach
(
function
(
app
)
{
scope
.
cop
i
edApps
.
forEach
(
function
(
app
)
{
app
.
selected
=
false
;
app
.
selected
=
false
;
})
})
...
@@ -117,6 +118,10 @@ directive_module.directive('apollonav',
...
@@ -117,6 +118,10 @@ directive_module.directive('apollonav',
},
function
(
result
)
{
},
function
(
result
)
{
});
});
PermissionService
.
has_root_permission
().
then
(
function
(
result
)
{
scope
.
hasRootPermission
=
result
.
hasPermission
;
})
}
}
}
}
...
...
apollo-portal/src/main/resources/static/server_config.html
View file @
9c71307c
...
@@ -21,6 +21,7 @@
...
@@ -21,6 +21,7 @@
<div
class=
"panel"
>
<div
class=
"panel"
>
<header
class=
"panel-heading"
>
<header
class=
"panel-heading"
>
应用配置
应用配置
<small>
(维护ServerConfig表数据,如果已存在配置项则会覆盖,否则会创建配置项。配置更新后,一分钟后自动生效)
</small>
</header>
</header>
<div
class=
"panel-body"
>
<div
class=
"panel-body"
>
...
@@ -53,7 +54,7 @@
...
@@ -53,7 +54,7 @@
<div
class=
"form-group"
>
<div
class=
"form-group"
>
<div
class=
"col-sm-offset-2 col-sm-10"
>
<div
class=
"col-sm-offset-2 col-sm-10"
>
<button
type=
"submit"
class=
"btn btn-
default
"
>
提交
</button>
<button
type=
"submit"
class=
"btn btn-
primary
"
>
提交
</button>
</div>
</div>
</div>
</div>
</form>
</form>
...
@@ -86,6 +87,7 @@
...
@@ -86,6 +87,7 @@
<script
type=
"application/javascript"
src=
"scripts/services/UserService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/UserService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/CommonService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/ServerConfigService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/ServerConfigService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/PermissionService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/ServerConfigController.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/ServerConfigController.js"
></script>
</body>
</body>
...
...
apollo-portal/src/main/resources/static/user-manage.html
View file @
9c71307c
...
@@ -95,6 +95,7 @@
...
@@ -95,6 +95,7 @@
<script
type=
"application/javascript"
src=
"scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/AppUtils.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/OrganizationService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/OrganizationService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/directive/directive.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/directive/directive.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/services/PermissionService.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/UserController.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/UserController.js"
></script>
...
...
apollo-portal/src/main/resources/static/views/common/nav.html
View file @
9c71307c
...
@@ -25,6 +25,16 @@
...
@@ -25,6 +25,16 @@
<span
class=
"glyphicon glyphicon-question-sign"
></span>
帮助
<span
class=
"glyphicon glyphicon-question-sign"
></span>
帮助
</a>
</a>
</li>
</li>
<li
class=
"dropdown"
ng-if=
"hasRootPermission"
>
<a
href=
"#"
class=
"dropdown-toggle"
data-toggle=
"dropdown"
role=
"button"
aria-haspopup=
"true"
aria-expanded=
"false"
>
<span
class=
"glyphicon glyphicon-cog"
></span>
管理员工具
<span
class=
"caret"
></span></a>
<ul
class=
"dropdown-menu"
>
<li><a
href=
"/user-manage.html"
target=
"_blank"
>
用户管理
</a></li>
<li><a
href=
"/open/manage.html"
target=
"_blank"
>
开放平台授权管理
</a></li>
<li><a
href=
"/server_config.html"
target=
"_blank"
>
系统参数
</a></li>
</ul>
</li>
<li
class=
"dropdown"
>
<li
class=
"dropdown"
>
<a
href=
"#"
class=
"dropdown-toggle"
data-toggle=
"dropdown"
role=
"button"
aria-haspopup=
"true"
aria-expanded=
"false"
>
<a
href=
"#"
class=
"dropdown-toggle"
data-toggle=
"dropdown"
role=
"button"
aria-haspopup=
"true"
aria-expanded=
"false"
>
<span
class=
"glyphicon glyphicon-user"
></span>
{{userName}}
<span
class=
"glyphicon glyphicon-user"
></span>
{{userName}}
...
...
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