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
1c0d022a
Unverified
Commit
1c0d022a
authored
Jan 27, 2020
by
Marcus Andersson
Committed by
GitHub
Jan 27, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Dashboard: fixes issue with UI not being re-rendered after moving dashboard
parent
4e3ff196
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
public/app/features/manage-dashboards/components/MoveToFolderModal/MoveToFolderCtrl.ts
+8
-2
No files found.
public/app/features/manage-dashboards/components/MoveToFolderModal/MoveToFolderCtrl.ts
View file @
1c0d022a
...
@@ -2,6 +2,8 @@ import coreModule from 'app/core/core_module';
...
@@ -2,6 +2,8 @@ import coreModule from 'app/core/core_module';
import
appEvents
from
'app/core/app_events'
;
import
appEvents
from
'app/core/app_events'
;
import
{
backendSrv
}
from
'app/core/services/backend_srv'
;
import
{
backendSrv
}
from
'app/core/services/backend_srv'
;
import
{
AppEvents
}
from
'@grafana/data'
;
import
{
AppEvents
}
from
'@grafana/data'
;
import
{
IScope
}
from
'angular'
;
import
{
promiseToDigest
}
from
'app/core/utils/promiseToDigest'
;
export
class
MoveToFolderCtrl
{
export
class
MoveToFolderCtrl
{
dashboards
:
any
;
dashboards
:
any
;
...
@@ -10,12 +12,15 @@ export class MoveToFolderCtrl {
...
@@ -10,12 +12,15 @@ export class MoveToFolderCtrl {
afterSave
:
any
;
afterSave
:
any
;
isValidFolderSelection
=
true
;
isValidFolderSelection
=
true
;
constructor
(
private
$scope
:
IScope
)
{}
onFolderChange
(
folder
:
any
)
{
onFolderChange
(
folder
:
any
)
{
this
.
folder
=
folder
;
this
.
folder
=
folder
;
}
}
save
()
{
save
()
{
return
backendSrv
.
moveDashboards
(
this
.
dashboards
,
this
.
folder
).
then
((
result
:
any
)
=>
{
return
promiseToDigest
(
this
.
$scope
)(
backendSrv
.
moveDashboards
(
this
.
dashboards
,
this
.
folder
).
then
((
result
:
any
)
=>
{
if
(
result
.
successCount
>
0
)
{
if
(
result
.
successCount
>
0
)
{
const
header
=
`Dashboard
${
result
.
successCount
===
1
?
''
:
's'
}
Moved`
;
const
header
=
`Dashboard
${
result
.
successCount
===
1
?
''
:
's'
}
Moved`
;
const
msg
=
`
${
result
.
successCount
}
dashboard
${
result
.
successCount
===
1
?
''
:
's'
}
moved to
${
const
msg
=
`
${
result
.
successCount
}
dashboard
${
result
.
successCount
===
1
?
''
:
's'
}
moved to
${
...
@@ -30,7 +35,8 @@ export class MoveToFolderCtrl {
...
@@ -30,7 +35,8 @@ export class MoveToFolderCtrl {
this
.
dismiss
();
this
.
dismiss
();
return
this
.
afterSave
();
return
this
.
afterSave
();
});
})
);
}
}
onEnterFolderCreation
()
{
onEnterFolderCreation
()
{
...
...
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