[pve-devel] r6346 - in pve-manager/pve2/www/manager: . dc node

svn-commits at proxmox.com svn-commits at proxmox.com
Thu Jul 21 13:36:54 CEST 2011


Author: dietmar
Date: 2011-07-21 13:36:54 +0200 (Thu, 21 Jul 2011)
New Revision: 6346

Modified:
   pve-manager/pve2/www/manager/VNCConsole.js
   pve-manager/pve2/www/manager/dc/AuthView.js
   pve-manager/pve2/www/manager/dc/GroupView.js
   pve-manager/pve2/www/manager/dc/StorageView.js
   pve-manager/pve2/www/manager/dc/UserView.js
   pve-manager/pve2/www/manager/node/NetworkView.js
   pve-manager/pve2/www/manager/node/Summary.js
Log:
use waitMsgTarget


Modified: pve-manager/pve2/www/manager/VNCConsole.js
===================================================================
--- pve-manager/pve2/www/manager/VNCConsole.js	2011-07-21 11:26:43 UTC (rev 6345)
+++ pve-manager/pve2/www/manager/VNCConsole.js	2011-07-21 11:36:54 UTC (rev 6346)
@@ -180,14 +180,11 @@
 	}
 
 	var vm_command = function(cmd, reload_applet) {
-	    me.setLoading(true, true);
 	    PVE.Utils.API2Request({
 		params: { command: cmd },
 		url: '/nodes/' + me.nodename + '/qemu/' + me.vmid + "/status",
 		method: 'PUT',
-		callback: function() {
-		    me.setLoading(false);
-		},
+		waitMsgTarget: me,
 		failure: function(response, opts) {
 		    Ext.Msg.alert('Error', response.htmlStatus);
 		},

Modified: pve-manager/pve2/www/manager/dc/AuthView.js
===================================================================
--- pve-manager/pve2/www/manager/dc/AuthView.js	2011-07-21 11:26:43 UTC (rev 6345)
+++ pve-manager/pve2/www/manager/dc/AuthView.js	2011-07-21 11:36:54 UTC (rev 6346)
@@ -65,12 +65,11 @@
 				return;
 			    }
 
-			    me.setLoading(true, true);
 			    PVE.Utils.API2Request({
 				url: '/access/domains/' + realm,
 				method: 'DELETE',
+				waitMsgTarget: me,
 				callback: function() {
-				    me.setLoading(false);
 				    reload();
 				},
 				failure: function (response, opts) {

Modified: pve-manager/pve2/www/manager/dc/GroupView.js
===================================================================
--- pve-manager/pve2/www/manager/dc/GroupView.js	2011-07-21 11:26:43 UTC (rev 6345)
+++ pve-manager/pve2/www/manager/dc/GroupView.js	2011-07-21 11:36:54 UTC (rev 6346)
@@ -47,12 +47,11 @@
 			if (btn !== 'yes') {
 			    return;
 			}
-			me.setLoading(true, true);
 			PVE.Utils.API2Request({
 			    url: '/access/groups/' + groupid,
 			    method: 'DELETE',
+			    waitMsgTarget: me,
 			    callback: function() {
-				me.setLoading(false);
 				reload();
 			    },
 			    failure: function (response, opts) {

Modified: pve-manager/pve2/www/manager/dc/StorageView.js
===================================================================
--- pve-manager/pve2/www/manager/dc/StorageView.js	2011-07-21 11:26:43 UTC (rev 6345)
+++ pve-manager/pve2/www/manager/dc/StorageView.js	2011-07-21 11:36:54 UTC (rev 6346)
@@ -70,12 +70,11 @@
 		    if (btn !== 'yes') {
 			return;
 		    }
-		    me.setLoading(true, true);
 		    PVE.Utils.API2Request({
 			url: '/storage/' + rec.data.storage,
 			method: 'DELETE',
+			waitMsgTarget: me,
 			callback: function() {
-			    me.setLoading(false);
 			    reload();
 			},
 			failure: function (response, opts) {

Modified: pve-manager/pve2/www/manager/dc/UserView.js
===================================================================
--- pve-manager/pve2/www/manager/dc/UserView.js	2011-07-21 11:26:43 UTC (rev 6345)
+++ pve-manager/pve2/www/manager/dc/UserView.js	2011-07-21 11:36:54 UTC (rev 6346)
@@ -70,12 +70,11 @@
 				return;
 			    }
 
-			    me.setLoading(true, true);
 			    PVE.Utils.API2Request({
 				url: '/access/users/' + userid,
 				method: 'DELETE',
+				waitMsgTarget: me,
 				callback: function() {
-				    me.setLoading(false);
 				    reload();
 				},
 				failure: function (response, opts) {

Modified: pve-manager/pve2/www/manager/node/NetworkView.js
===================================================================
--- pve-manager/pve2/www/manager/node/NetworkView.js	2011-07-21 11:26:43 UTC (rev 6345)
+++ pve-manager/pve2/www/manager/node/NetworkView.js	2011-07-21 11:36:54 UTC (rev 6346)
@@ -88,12 +88,11 @@
 
 		var iface = rec.data.iface;
 
-		me.setLoading(true, true);
 		PVE.Utils.API2Request({
 		    url: '/nodes/' + nodename + '/network/' + iface,
 		    method: 'DELETE',
+		    waitMsgTarget: me,
 		    callback: function() {
-			me.setLoading(false);
 			reload();
 		    },
 		    failure: function(response, opts) {
@@ -179,12 +178,11 @@
 		{
 		    text: 'Revert changes',
 		    handler: function() {
-			me.setLoading(true, true);
 			PVE.Utils.API2Request({
 			    url: '/nodes/' + nodename + '/network_changes',
 			    method: 'DELETE',
+			    waitMsgTarget: me,
 			    callback: function() {
-				me.setLoading(false);
 				reload();
 			    },
 			    failure: function(response, opts) {

Modified: pve-manager/pve2/www/manager/node/Summary.js
===================================================================
--- pve-manager/pve2/www/manager/node/Summary.js	2011-07-21 11:26:43 UTC (rev 6345)
+++ pve-manager/pve2/www/manager/node/Summary.js	2011-07-21 11:36:54 UTC (rev 6346)
@@ -19,14 +19,11 @@
 	var rstore = statusview.rstore;
 
 	var node_command = function(cmd) {
-	    me.setLoading(true, true);
 	    PVE.Utils.API2Request({
 		params: { command: cmd },
 		url: '/nodes/' + nodename + '/status',
 		method: 'POST',
-		callback: function() {
-		    me.setLoading(false);
-		},
+		waitMsgTarget: me,
 		failure: function(response, opts) {
 		    Ext.Msg.alert('Error', response.htmlStatus);
 		}




More information about the pve-devel mailing list