Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
fee48464
Commit
fee48464
authored
Jan 25, 2017
by
Torkel Ödegaard
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'alerting_ui' of
https://github.com/smalik03/grafana
into smalik03-alerting_ui
parents
4e30aa9d
9862c9ff
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
9 additions
and
3 deletions
+9
-3
conf/defaults.ini
+1
-0
pkg/api/frontendsettings.go
+1
-0
pkg/api/index.go
+1
-1
pkg/setting/setting.go
+3
-1
public/app/plugins/panel/graph/module.ts
+3
-1
No files found.
conf/defaults.ini
View file @
fee48464
...
...
@@ -404,6 +404,7 @@ global_session = -1
[alerting]
# Makes it possible to turn off alert rule execution.
execute_alerts
=
true
show_alerting_ui
=
true
#################################### Internal Grafana Metrics ############
# Metrics available at HTTP API Url /api/metrics
...
...
pkg/api/frontendsettings.go
View file @
fee48464
...
...
@@ -140,6 +140,7 @@ func getFrontendSettingsMap(c *middleware.Context) (map[string]interface{}, erro
"allowOrgCreate"
:
(
setting
.
AllowUserOrgCreate
&&
c
.
IsSignedIn
)
||
c
.
IsGrafanaAdmin
,
"authProxyEnabled"
:
setting
.
AuthProxyEnabled
,
"ldapEnabled"
:
setting
.
LdapEnabled
,
"showAlertingUI"
:
setting
.
ShowAlertingUI
,
"buildInfo"
:
map
[
string
]
interface
{}{
"version"
:
setting
.
BuildVersion
,
"commit"
:
setting
.
BuildCommit
,
...
...
pkg/api/index.go
View file @
fee48464
...
...
@@ -103,7 +103,7 @@ func setIndexViewData(c *middleware.Context) (*dtos.IndexViewData, error) {
Children
:
dashboardChildNavs
,
})
if
c
.
OrgRole
==
m
.
ROLE_ADMIN
||
c
.
OrgRole
==
m
.
ROLE_EDITOR
{
if
setting
.
ShowAlertingUI
&&
(
c
.
OrgRole
==
m
.
ROLE_ADMIN
||
c
.
OrgRole
==
m
.
ROLE_EDITOR
)
{
alertChildNavs
:=
[]
*
dtos
.
NavLink
{
{
Text
:
"Alert List"
,
Url
:
setting
.
AppSubUrl
+
"/alerting/list"
},
{
Text
:
"Notification channels"
,
Url
:
setting
.
AppSubUrl
+
"/alerting/notifications"
},
...
...
pkg/setting/setting.go
View file @
fee48464
...
...
@@ -150,7 +150,8 @@ var (
Quota
QuotaSettings
// Alerting
ExecuteAlerts
bool
ExecuteAlerts
bool
ShowAlertingUI
bool
// logger
logger
log
.
Logger
...
...
@@ -579,6 +580,7 @@ func NewConfigContext(args *CommandLineArgs) error {
alerting
:=
Cfg
.
Section
(
"alerting"
)
ExecuteAlerts
=
alerting
.
Key
(
"execute_alerts"
)
.
MustBool
(
true
)
ShowAlertingUI
=
alerting
.
Key
(
"show_alerting_ui"
)
.
MustBool
(
true
)
readSessionConfig
()
readSmtpSettings
()
...
...
public/app/plugins/panel/graph/module.ts
View file @
fee48464
...
...
@@ -132,7 +132,9 @@ class GraphCtrl extends MetricsPanelCtrl {
this
.
addEditorTab
(
'Axes'
,
axesEditorComponent
,
2
);
this
.
addEditorTab
(
'Legend'
,
'public/app/plugins/panel/graph/tab_legend.html'
,
3
);
this
.
addEditorTab
(
'Display'
,
'public/app/plugins/panel/graph/tab_display.html'
,
4
);
this
.
addEditorTab
(
'Alert'
,
alertTab
,
5
);
if
(
config
.
showAlertingUI
)
{
this
.
addEditorTab
(
'Alert'
,
alertTab
,
5
);
}
this
.
subTabIndex
=
0
;
}
...
...
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