Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
spring-boot-admin
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
spring-boot-admin
Commits
09b8a956
Commit
09b8a956
authored
Oct 11, 2016
by
Dmitry Shmatko
Committed by
Johannes Edmeier
Oct 12, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add a referesh button to details
Instead of alway hitting F5 and do a full page reload, this adds a small button to refresh the details view.
parent
880f10f0
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
38 additions
and
27 deletions
+38
-27
detailsCtrl.js
...i/modules/applications-details/controllers/detailsCtrl.js
+31
-27
details.html
...server-ui/modules/applications-details/views/details.html
+7
-0
No files found.
spring-boot-admin-server-ui/modules/applications-details/controllers/detailsCtrl.js
View file @
09b8a956
...
...
@@ -23,33 +23,37 @@ module.exports = function ($scope, application) {
$scope
.
application
=
application
;
$scope
.
metrics
=
{};
application
.
getInfo
().
then
(
function
(
response
)
{
$scope
.
info
=
response
.
data
;
}).
catch
(
function
(
response
)
{
$scope
.
error
=
response
.
data
;
});
$scope
.
getDetails
=
function
()
{
application
.
getInfo
().
then
(
function
(
response
)
{
$scope
.
info
=
response
.
data
;
}).
catch
(
function
(
response
)
{
$scope
.
error
=
response
.
data
;
});
application
.
getHealth
().
then
(
function
(
response
)
{
$scope
.
health
=
response
.
data
;
}).
catch
(
function
(
response
)
{
$scope
.
health
=
response
.
data
;
});
application
.
getHealth
().
then
(
function
(
response
)
{
$scope
.
health
=
response
.
data
;
}).
catch
(
function
(
response
)
{
$scope
.
health
=
response
.
data
;
});
application
.
getMetrics
().
then
(
function
(
response
)
{
$scope
.
metrics
=
response
.
data
;
$scope
.
hasDatasources
=
false
;
$scope
.
hasCaches
=
false
;
angular
.
forEach
(
$scope
.
metrics
,
function
(
value
,
key
)
{
if
(
!
$scope
.
hasDatasources
&&
key
.
startsWith
(
'datasource.'
))
{
$scope
.
hasDatasources
=
true
;
}
if
(
!
$scope
.
hasCaches
&&
key
.
startsWith
(
'cache.'
))
{
$scope
.
hasCaches
=
true
;
}
});
}
).
catch
(
function
(
response
)
{
$scope
.
error
=
response
.
data
;
});
application
.
getMetrics
().
then
(
function
(
response
)
{
$scope
.
metrics
=
response
.
data
;
$scope
.
hasDatasources
=
false
;
$scope
.
hasCaches
=
false
;
angular
.
forEach
(
$scope
.
metrics
,
function
(
value
,
key
)
{
if
(
!
$scope
.
hasDatasources
&&
key
.
startsWith
(
'datasource.'
))
{
$scope
.
hasDatasources
=
true
;
}
if
(
!
$scope
.
hasCaches
&&
key
.
startsWith
(
'cache.'
))
{
$scope
.
hasCaches
=
true
;
}
});
}
).
catch
(
function
(
response
)
{
$scope
.
error
=
response
.
data
;
});
};
$scope
.
getDetails
();
};
spring-boot-admin-server-ui/modules/applications-details/views/details.html
View file @
09b8a956
...
...
@@ -2,6 +2,13 @@
<div
class=
"alert alert-error"
ng-if=
"error"
>
<b>
Error:
</b>
{{ error }}
</div>
<div
class=
"row"
>
<div
class=
"text-center"
>
<form>
<button
class=
"btn"
ng-click=
"getDetails()"
><i
class=
"fa fa-repeat"
></i>
refresh
</button>
</form>
</div>
</div>
<div
style=
"display: flex; flex-wrap: wrap; justify-content: space-around;"
>
<sba-info-panel
class=
"span6"
style=
"margin-left:0px"
panel-title=
"Application"
raw=
"api/applications/{{ application.id }}/info"
>
<table
class=
"table"
>
...
...
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