From 644a9bc5323317bd70616ba47fa53be98a9950ad Mon Sep 17 00:00:00 2001 From: Jessica Wang Date: Thu, 9 Jan 2014 11:22:06 -0800 Subject: [PATCH] CLOUDSTACK-5840: UI > Secondary Storages > remove "prepareObjectStoreMigration" action (since prepareSecondaryStorageForMigration API has been removed from server-side). --- ui/scripts/system.js | 40 ++--------------------------- ui/scripts/ui/widgets/detailView.js | 8 +----- 2 files changed, 3 insertions(+), 45 deletions(-) diff --git a/ui/scripts/system.js b/ui/scripts/system.js index a5f6ffefa47..8558de91077 100644 --- a/ui/scripts/system.js +++ b/ui/scripts/system.js @@ -16145,38 +16145,7 @@ detailView: { name: 'Secondary storage details', isMaximized: true, - actions: { - prepareObjectStoreMigration: { - label: 'Prepare Object Store Migration', - messages: { - confirm: function(args) { - return 'Please confirm you want to prepare migration of secondary storage to object store.'; - }, - notification: function(args) { - return 'Prepare Object Store Migration'; - } - }, - action: function(args) { - $.ajax({ - url: createURL('prepareSecondaryStorageForMigration'), - data: { - id: args.context.secondaryStorage[0].id - }, - success: function(json) { - var jid = json.preparesecondarystorageformigrationresponse.jobid; - args.response.success({ - _custom: { - jobId: jid - } - }); - } - }); - }, - notification: { - poll: pollAsyncJobResult - } - }, - + actions: { remove: { label: 'label.action.delete.secondary.storage', messages: { @@ -17687,12 +17656,7 @@ var secondarystorageActionfilter = function(args) { var jsonObj = args.context.item; var allowedActions = []; - allowedActions.push("remove"); - - if (jsonObj.providername == 'NFS') { - allowedActions.push("prepareObjectStoreMigration"); - } - + allowedActions.push("remove"); return allowedActions; } diff --git a/ui/scripts/ui/widgets/detailView.js b/ui/scripts/ui/widgets/detailView.js index d29f32ebc8c..9ca4ddda7a4 100644 --- a/ui/scripts/ui/widgets/detailView.js +++ b/ui/scripts/ui/widgets/detailView.js @@ -380,13 +380,7 @@ } }); }, - - prepareObjectStoreMigration: function($detailView, args) { - var tab = args.tabs[args.activeTab]; - var isMultiple = tab.multiple; - uiActions.remove($detailView, args); - }, - + destroy: function($detailView, args) { var tab = args.tabs[args.activeTab]; var isMultiple = tab.multiple;