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
dba7062f
Commit
dba7062f
authored
Mar 05, 2015
by
Torkel Ödegaard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Some more polish to confirm dialogs
parent
6786ffff
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
0 deletions
+8
-0
src/app/features/admin/adminUsersCtrl.js
+2
-0
src/app/features/dashboard/dashboardNavCtrl.js
+2
-0
src/app/features/dashboard/rowCtrl.js
+4
-0
No files found.
src/app/features/admin/adminUsersCtrl.js
View file @
dba7062f
...
@@ -21,6 +21,8 @@ function (angular) {
...
@@ -21,6 +21,8 @@ function (angular) {
$scope
.
deleteUser
=
function
(
user
)
{
$scope
.
deleteUser
=
function
(
user
)
{
$scope
.
appEvent
(
'confirm-modal'
,
{
$scope
.
appEvent
(
'confirm-modal'
,
{
title
:
'Do you want to delete '
+
user
.
login
+
'?'
,
title
:
'Do you want to delete '
+
user
.
login
+
'?'
,
icon
:
'fa-trash'
,
yesText
:
'Delete'
,
onConfirm
:
function
()
{
onConfirm
:
function
()
{
backendSrv
.
delete
(
'/api/admin/users/'
+
user
.
id
).
then
(
function
()
{
backendSrv
.
delete
(
'/api/admin/users/'
+
user
.
id
).
then
(
function
()
{
$scope
.
getUsers
();
$scope
.
getUsers
();
...
...
src/app/features/dashboard/dashboardNavCtrl.js
View file @
dba7062f
...
@@ -105,6 +105,8 @@ function (angular, _, moment) {
...
@@ -105,6 +105,8 @@ function (angular, _, moment) {
$scope
.
deleteDashboard
=
function
()
{
$scope
.
deleteDashboard
=
function
()
{
$scope
.
appEvent
(
'confirm-modal'
,
{
$scope
.
appEvent
(
'confirm-modal'
,
{
title
:
'Do you want to delete dashboard '
+
$scope
.
dashboard
.
title
+
'?'
,
title
:
'Do you want to delete dashboard '
+
$scope
.
dashboard
.
title
+
'?'
,
icon
:
'fa-trash'
,
yesText
:
'Delete'
,
onConfirm
:
function
()
{
onConfirm
:
function
()
{
$scope
.
deleteDashboardConfirmed
();
$scope
.
deleteDashboardConfirmed
();
}
}
...
...
src/app/features/dashboard/rowCtrl.js
View file @
dba7062f
...
@@ -50,6 +50,8 @@ function (angular, app, _, config) {
...
@@ -50,6 +50,8 @@ function (angular, app, _, config) {
$scope
.
delete_row
=
function
()
{
$scope
.
delete_row
=
function
()
{
$scope
.
appEvent
(
'confirm-modal'
,
{
$scope
.
appEvent
(
'confirm-modal'
,
{
title
:
'Are you sure you want to delete this row?'
,
title
:
'Are you sure you want to delete this row?'
,
icon
:
'fa-trash'
,
yesText
:
'delete'
,
onConfirm
:
function
()
{
onConfirm
:
function
()
{
$scope
.
dashboard
.
rows
=
_
.
without
(
$scope
.
dashboard
.
rows
,
$scope
.
row
);
$scope
.
dashboard
.
rows
=
_
.
without
(
$scope
.
dashboard
.
rows
,
$scope
.
row
);
}
}
...
@@ -82,6 +84,8 @@ function (angular, app, _, config) {
...
@@ -82,6 +84,8 @@ function (angular, app, _, config) {
$scope
.
remove_panel_from_row
=
function
(
row
,
panel
)
{
$scope
.
remove_panel_from_row
=
function
(
row
,
panel
)
{
$scope
.
appEvent
(
'confirm-modal'
,
{
$scope
.
appEvent
(
'confirm-modal'
,
{
title
:
'Are you sure you want to remove this panel?'
,
title
:
'Are you sure you want to remove this panel?'
,
icon
:
'fa-trash'
,
yesText
:
'Delete'
,
onConfirm
:
function
()
{
onConfirm
:
function
()
{
row
.
panels
=
_
.
without
(
row
.
panels
,
panel
);
row
.
panels
=
_
.
without
(
row
.
panels
,
panel
);
}
}
...
...
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