mirror of https://github.com/apache/cloudstack.git
Merge pull request #1505 from pdube/CLOUDSTACK-9172-delete-cross-zones-template
CLOUDSTACK-9172 Added cross zones check to delete template and isoAdded a check to ignore the zoneid, in the delete template UI, if the template is cross zones. reference : CLOUDSTACK-9172 * pr/1505: CLOUDSTACK-9172 Added cross zones check to delete template and iso Signed-off-by: Will Stevens <williamstevens@gmail.com>
This commit is contained in:
commit
d13ff88cbc
|
|
@ -1451,8 +1451,12 @@
|
|||
}
|
||||
},
|
||||
action: function(args) {
|
||||
var queryParams = "deleteTemplate&id=" + args.context.templates[0].id;
|
||||
if (!args.context.templates[0].crossZones){
|
||||
queryParams += "&zoneid=" + args.context.zones[0].zoneid;
|
||||
}
|
||||
$.ajax({
|
||||
url: createURL("deleteTemplate&id=" + args.context.templates[0].id + "&zoneid=" + args.context.zones[0].zoneid),
|
||||
url: createURL(queryParams),
|
||||
dataType: "json",
|
||||
async: true,
|
||||
success: function(json) {
|
||||
|
|
@ -2536,12 +2540,12 @@
|
|||
}
|
||||
},
|
||||
action: function(args) {
|
||||
var array1 = [];
|
||||
if (args.context.zones[0].zoneid != null)
|
||||
array1.push("&zoneid=" + args.context.zones[0].zoneid);
|
||||
|
||||
var queryParams = "deleteIso&id=" + args.context.isos[0].id;
|
||||
if (!args.context.isos[0].crossZones){
|
||||
queryParams += "&zoneid=" + args.context.zones[0].zoneid;
|
||||
}
|
||||
$.ajax({
|
||||
url: createURL("deleteIso&id=" + args.context.isos[0].id + "&zoneid=" + args.context.zones[0].zoneid),
|
||||
url: createURL(queryParams),
|
||||
dataType: "json",
|
||||
async: true,
|
||||
success: function(json) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue