mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
Network page - external firewall tab, external load balancer tab - show warning message when delete firewall/load balancer action is clicked.
This commit is contained in:
parent
8fbc19bfac
commit
1667ee173b
@ -4,6 +4,8 @@ label.action.destroy.systemvm.processing=Destroying System VM....
|
|||||||
message.action.destroy.systemvm=Please confirm you want to destroy System VM
|
message.action.destroy.systemvm=Please confirm you want to destroy System VM
|
||||||
label.numretries = Number of Retries
|
label.numretries = Number of Retries
|
||||||
label.timeout.in.second = Timeout(seconds)
|
label.timeout.in.second = Timeout(seconds)
|
||||||
|
message.action.delete.external.firewall=Please confirm that you would like to remove this external firewall. Warning: If you are planning to add back the same external firewall, you must reset usage data on the device.
|
||||||
|
message.action.delete.external.load.balancer=Please confirm that you would like to remove this external load balancer. Warning: If you are planning to add back the same external load balancer, you must reset usage data on the device.
|
||||||
|
|
||||||
#Labels
|
#Labels
|
||||||
label.account.id=Account ID
|
label.account.id=Account ID
|
||||||
|
|||||||
@ -15,7 +15,9 @@ dictionary = {
|
|||||||
'label.action.delete.load.balancer.processing' : '<fmt:message key="label.action.delete.load.balancer.processing"/>',
|
'label.action.delete.load.balancer.processing' : '<fmt:message key="label.action.delete.load.balancer.processing"/>',
|
||||||
'label.action.delete.network' : '<fmt:message key="label.action.delete.network"/>',
|
'label.action.delete.network' : '<fmt:message key="label.action.delete.network"/>',
|
||||||
'label.action.delete.network.processing' : '<fmt:message key="label.action.delete.network.processing"/>',
|
'label.action.delete.network.processing' : '<fmt:message key="label.action.delete.network.processing"/>',
|
||||||
'message.action.delete.network' : '<fmt:message key="message.action.delete.network"/>'
|
'message.action.delete.network' : '<fmt:message key="message.action.delete.network"/>',
|
||||||
|
'message.action.delete.external.firewall': '<fmt:message key="message.action.delete.external.firewall"/>',
|
||||||
|
'message.action.delete.external.load.balancer': '<fmt:message key="message.action.delete.external.load.balancer"/>'
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@ -364,9 +364,9 @@ function publicNetworkFirewallJsonToTemplate(jsonObj, $template) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
var publicNetworkFirewallActionMap = {
|
var publicNetworkFirewallActionMap = {
|
||||||
"label.action.delete.firewall": {
|
"label.action.delete.firewall": {
|
||||||
api: "deleteExternalFirewall",
|
isAsyncJob: false,
|
||||||
isAsyncJob: false,
|
dialogBeforeActionFn : doDeleteExternalFirewall,
|
||||||
inProcessText: "label.action.delete.firewall.processing",
|
inProcessText: "label.action.delete.firewall.processing",
|
||||||
afterActionSeccessFn: function(json, id, $subgridItem) {
|
afterActionSeccessFn: function(json, id, $subgridItem) {
|
||||||
$subgridItem.slideUp("slow", function() {
|
$subgridItem.slideUp("slow", function() {
|
||||||
@ -376,6 +376,23 @@ var publicNetworkFirewallActionMap = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function doDeleteExternalFirewall($actionLink, $subgridItem) {
|
||||||
|
var jsonObj = $subgridItem.data("jsonObj");
|
||||||
|
var id = jsonObj.id;
|
||||||
|
|
||||||
|
$("#dialog_confirmation")
|
||||||
|
.text(dictionary["message.action.delete.external.firewall"])
|
||||||
|
.dialog('option', 'buttons', {
|
||||||
|
"Confirm": function() {
|
||||||
|
$(this).dialog("close");
|
||||||
|
var apiCommand = "command=deleteExternalFirewall&id="+id;
|
||||||
|
doActionToSubgridItem(id, $actionLink, apiCommand, $subgridItem);
|
||||||
|
},
|
||||||
|
"Cancel": function() {
|
||||||
|
$(this).dialog("close");
|
||||||
|
}
|
||||||
|
}).dialog("open");
|
||||||
|
}
|
||||||
|
|
||||||
function publicNetworkJsonToLoadBalancerTab() {
|
function publicNetworkJsonToLoadBalancerTab() {
|
||||||
var $midmenuItem1 = $("#right_panel_content").data("$midmenuItem1");
|
var $midmenuItem1 = $("#right_panel_content").data("$midmenuItem1");
|
||||||
@ -442,9 +459,9 @@ function publicNetworkLoadBalancerJsonToTemplate(jsonObj, $template) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
var publicNetworkLoadBalancerActionMap = {
|
var publicNetworkLoadBalancerActionMap = {
|
||||||
"label.action.delete.load.balancer": {
|
"label.action.delete.load.balancer": {
|
||||||
api: "deleteExternalLoadBalancer",
|
isAsyncJob: false,
|
||||||
isAsyncJob: false,
|
dialogBeforeActionFn: doDeleteExternalLoadBalancer,
|
||||||
inProcessText: "label.action.delete.load.balancer.processing",
|
inProcessText: "label.action.delete.load.balancer.processing",
|
||||||
afterActionSeccessFn: function(json, id, $subgridItem) {
|
afterActionSeccessFn: function(json, id, $subgridItem) {
|
||||||
$subgridItem.slideUp("slow", function() {
|
$subgridItem.slideUp("slow", function() {
|
||||||
@ -454,6 +471,24 @@ var publicNetworkLoadBalancerActionMap = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function doDeleteExternalLoadBalancer($actionLink, $subgridItem) {
|
||||||
|
var jsonObj = $subgridItem.data("jsonObj");
|
||||||
|
var id = jsonObj.id;
|
||||||
|
|
||||||
|
$("#dialog_confirmation")
|
||||||
|
.text(dictionary["message.action.delete.external.load.balancer"])
|
||||||
|
.dialog('option', 'buttons', {
|
||||||
|
"Confirm": function() {
|
||||||
|
$(this).dialog("close");
|
||||||
|
var apiCommand = "command=deleteExternalLoadBalancer&id="+id;
|
||||||
|
doActionToSubgridItem(id, $actionLink, apiCommand, $subgridItem);
|
||||||
|
},
|
||||||
|
"Cancel": function() {
|
||||||
|
$(this).dialog("close");
|
||||||
|
}
|
||||||
|
}).dialog("open");
|
||||||
|
}
|
||||||
|
|
||||||
function bindAddIpRangeToPublicNetworkButton($button, $midmenuItem1) {
|
function bindAddIpRangeToPublicNetworkButton($button, $midmenuItem1) {
|
||||||
var jsonObj = $midmenuItem1.data("jsonObj");
|
var jsonObj = $midmenuItem1.data("jsonObj");
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user