From 27bfd62e0e37ca45fdda3a85f71b0e435052364e Mon Sep 17 00:00:00 2001 From: Jessica Wang Date: Fri, 2 Mar 2012 11:08:23 -0800 Subject: [PATCH] delete template action, delete ISO action - use 'remove' instead of 'destroy' since their definitions have been switched. --- ui/scripts/storage.js | 4 ++-- ui/scripts/templates.js | 24 ++++++------------------ 2 files changed, 8 insertions(+), 20 deletions(-) diff --git a/ui/scripts/storage.js b/ui/scripts/storage.js index 42892100342..e99369ee713 100644 --- a/ui/scripts/storage.js +++ b/ui/scripts/storage.js @@ -786,7 +786,7 @@ } }, - 'remove': { + remove: { label: 'label.action.delete.volume', messages: { confirm: function(args) { @@ -1089,7 +1089,7 @@ } }, - 'remove': { + remove: { label: 'label.action.delete.snapshot', messages: { confirm: function(args) { diff --git a/ui/scripts/templates.js b/ui/scripts/templates.js index d3867b1a251..c5be659ada2 100644 --- a/ui/scripts/templates.js +++ b/ui/scripts/templates.js @@ -503,7 +503,7 @@ } }, - 'delete': { + remove: { label: 'label.action.delete.template', messages: { confirm: function(args) { @@ -526,13 +526,7 @@ var jid = json.deletetemplateresponse.jobid; args.response.success( {_custom: - {jobId: jid, - getUpdatedItem: function(json) { - return {}; //nothing in this template needs to be updated, in fact, this whole template has being deleted - }, - getActionFilter: function() { - return templateActionfilter; - } + {jobId: jid } } ); @@ -1037,7 +1031,7 @@ } }, - 'delete': { + remove: { label: 'label.action.delete.ISO', messages: { confirm: function(args) { @@ -1060,13 +1054,7 @@ var jid = json.deleteisosresponse.jobid; args.response.success( {_custom: - {jobId: jid, - getUpdatedItem: function(json) { - return {}; //nothing in this ISO needs to be updated, in fact, this whole ISO has being deleted - }, - getActionFilter: function() { - return isoActionfilter; - } + {jobId: jid } } ); @@ -1224,7 +1212,7 @@ //do nothing } else { - allowedActions.push("delete"); + allowedActions.push("remove"); } return allowedActions; @@ -1284,7 +1272,7 @@ //do nothing } else { - allowedActions.push("delete"); + allowedActions.push("remove"); } return allowedActions;