incubator-cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jessicaw...@apache.org
Subject git commit: cloudstack 3.0 UI - infrastructure - Virtual Routers - detailView - add Reboot action to VPC Virtual Router.
Date Wed, 08 Aug 2012 17:13:53 GMT
Updated Branches:
  refs/heads/vpc a1143acf8 -> 0c8ce06f6


cloudstack 3.0 UI - infrastructure - Virtual Routers - detailView - add Reboot action to VPC
Virtual Router.


Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/0c8ce06f
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/0c8ce06f
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/0c8ce06f

Branch: refs/heads/vpc
Commit: 0c8ce06f6b092dacfbd2d081ae347b9713f94e44
Parents: a1143ac
Author: Jessica Wang <jessica.wang@citrix.com>
Authored: Mon Aug 6 16:36:35 2012 -0700
Committer: Jessica Wang <jessica.wang@citrix.com>
Committed: Wed Aug 8 10:13:17 2012 -0700

----------------------------------------------------------------------
 ui/scripts/system.js |   38 +++++++++++++++++++++++++++++++++++++-
 1 files changed, 37 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/0c8ce06f/ui/scripts/system.js
----------------------------------------------------------------------
diff --git a/ui/scripts/system.js b/ui/scripts/system.js
index 1c48d08..bc6ebe3 100644
--- a/ui/scripts/system.js
+++ b/ui/scripts/system.js
@@ -4952,7 +4952,43 @@
                   poll: pollAsyncJobResult
                 }
               },
-          			  
+							
+							restart: {
+								label: 'label.action.reboot.router',
+								messages: {
+									confirm: function(args) {
+										return 'message.action.reboot.router';
+									},
+									notification: function(args) {
+										return 'label.action.reboot.router';
+									}
+								},
+								action: function(args) {
+									$.ajax({
+										url: createURL('rebootRouter&id=' + args.context.routers[0].id),
+										dataType: 'json',
+										async: true,
+										success: function(json) {
+											var jid = json.rebootrouterresponse.jobid;
+											args.response.success({
+												_custom: {
+													jobId: jid,
+													getUpdatedItem: function(json) {
+														return json.queryasyncjobresultresponse.jobresult.domainrouter;
+													},
+													getActionFilter: function() {
+														return routerActionfilter;
+													}
+												}
+											});
+										}
+									});
+								},
+								notification: {
+									poll: pollAsyncJobResult
+								}
+							},              							
+									
 							changeService: {
 								label: 'label.change.service.offering',
 								createForm: {


Mime
View raw message