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
8fc648ac
Commit
8fc648ac
authored
Jan 31, 2018
by
Marcus Efraimsson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dashboards: fix updating folder so that correct url is returned
parent
035b7247
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
2 deletions
+13
-2
public/app/core/services/backend_srv.ts
+11
-0
public/app/features/dashboard/folder_settings_ctrl.ts
+2
-2
No files found.
public/app/core/services/backend_srv.ts
View file @
8fc648ac
...
...
@@ -257,6 +257,17 @@ export class BackendSrv {
});
}
updateDashboardFolder
(
dash
,
options
)
{
options
=
options
||
{};
return
this
.
post
(
'/api/dashboards/db/'
,
{
dashboard
:
dash
,
isFolder
:
true
,
overwrite
:
options
.
overwrite
===
true
,
message
:
options
.
message
||
''
,
});
}
deleteDashboard
(
uid
)
{
let
deferred
=
this
.
$q
.
defer
();
...
...
public/app/features/dashboard/folder_settings_ctrl.ts
View file @
8fc648ac
...
...
@@ -37,7 +37,7 @@ export class FolderSettingsCtrl {
this
.
dashboard
.
title
=
this
.
title
.
trim
();
return
this
.
backendSrv
.
saveDashboard
(
this
.
dashboard
,
{
overwrite
:
false
})
.
updateDashboardFolder
(
this
.
dashboard
,
{
overwrite
:
false
})
.
then
(
result
=>
{
if
(
result
.
url
!==
this
.
$location
.
path
())
{
this
.
$location
.
url
(
result
.
url
+
'/settings'
);
...
...
@@ -84,7 +84,7 @@ export class FolderSettingsCtrl {
yesText
:
'Save & Overwrite'
,
icon
:
'fa-warning'
,
onConfirm
:
()
=>
{
this
.
backendSrv
.
saveDashboard
(
this
.
dashboard
,
{
overwrite
:
true
});
this
.
backendSrv
.
updateDashboardFolder
(
this
.
dashboard
,
{
overwrite
:
true
});
},
});
}
...
...
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