Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
gitlab-ce
Commits
761fa974
Commit
761fa974
authored
Apr 15, 2019
by
Jose Vargas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make the monitoring bundle reusable
Also push the frontend flag in the clusters controller
parent
cd509d99
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
1 deletion
+5
-1
app/assets/javascripts/monitoring/monitoring_bundle.js
app/assets/javascripts/monitoring/monitoring_bundle.js
+2
-1
app/controllers/clusters/clusters_controller.rb
app/controllers/clusters/clusters_controller.rb
+3
-0
No files found.
app/assets/javascripts/monitoring/monitoring_bundle.js
View file @
761fa974
...
...
@@ -2,7 +2,7 @@ import Vue from 'vue';
import
{
parseBoolean
}
from
'
~/lib/utils/common_utils
'
;
import
Dashboard
from
'
./components/dashboard.vue
'
;
export
default
()
=>
{
export
default
(
props
=
{}
)
=>
{
const
el
=
document
.
getElementById
(
'
prometheus-graphs
'
);
if
(
el
&&
el
.
dataset
)
{
...
...
@@ -15,6 +15,7 @@ export default () => {
...
el
.
dataset
,
hasMetrics
:
parseBoolean
(
el
.
dataset
.
hasMetrics
),
showTimeWindowDropdown
:
gon
.
features
.
metricsTimeWindow
,
...
props
,
},
});
},
...
...
app/controllers/clusters/clusters_controller.rb
View file @
761fa974
...
...
@@ -12,6 +12,9 @@ class Clusters::ClustersController < Clusters::BaseController
before_action
:authorize_update_cluster!
,
only:
[
:update
]
before_action
:authorize_admin_cluster!
,
only:
[
:destroy
]
before_action
:update_applications_status
,
only:
[
:cluster_status
]
before_action
only:
[
:show
]
do
push_frontend_feature_flag
(
:metrics_time_window
)
end
helper_method
:token_in_session
...
...
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