cloudstack 3.0 UI - VPC - gateways - static route - implement Remove action.

This commit is contained in:
Jessica Wang 2012-07-11 14:50:57 -07:00
parent c5f8712b4b
commit b727c58497
1 changed files with 23 additions and 7 deletions

View File

@ -561,15 +561,31 @@
},
actions: {
destroy: {
label: 'Remove ACL',
action: function(args) {
args.response.success({
notification: {
label: 'Remove static route from gateway',
poll: function(args) { args.complete(); }
label: 'Remove static route',
action: function(args) {
//debugger;
$.ajax({
url: createURL('deleteStaticRoute'),
data: {
id: args.context.multiRule[0].id
},
dataType: 'json',
async: true,
success: function(data) {
var jobID = data.deletestaticrouteresponse.jobid;
args.response.success({
_custom: {
jobId: jobID
},
notification: {
label: 'Remove static route',
poll: pollAsyncJobResult
}
});
}
});
}
}
}
},
dataProvider: function(args) {