mirror of
https://github.com/apache/cloudstack.git
synced 2025-11-02 20:02:29 +01:00
bug 12358: cloudstack 3.0 new UI - hide copyTemplate and copyISO action for swift setup.
This commit is contained in:
parent
fea9ca582c
commit
a653db3f22
@ -234,6 +234,17 @@
|
||||
args.response.error();
|
||||
}
|
||||
});
|
||||
|
||||
$.ajax({
|
||||
url: createURL("listSwift"),
|
||||
dataType: "json",
|
||||
async: false,
|
||||
success: function(json) {
|
||||
var items = json.ListSwiftresponse.swift;
|
||||
if(items != null && items.length > 0)
|
||||
havingSwift = true;
|
||||
}
|
||||
});
|
||||
|
||||
// Get project configuration
|
||||
// TEMPORARY -- replace w/ output of capability response, etc., once implemented
|
||||
|
||||
@ -29,6 +29,7 @@ var md5HashedLogin = false;
|
||||
var pageSize = 20;
|
||||
|
||||
var rootAccountId = 1;
|
||||
var havingSwift = false;
|
||||
|
||||
//async action
|
||||
var pollAsyncJobResult = function(args) {
|
||||
|
||||
@ -3386,6 +3386,7 @@
|
||||
key: args.data.key
|
||||
},
|
||||
success: function(json) {
|
||||
havingSwift = true;
|
||||
args.response.success();
|
||||
},
|
||||
error: function(json) {
|
||||
|
||||
@ -1518,7 +1518,7 @@
|
||||
else {
|
||||
allowedActions.push("edit");
|
||||
|
||||
if(jsonObj.zoneid != null || jsonObj.zoneid != "-1")
|
||||
if(havingSwift == false)
|
||||
allowedActions.push("copyTemplate");
|
||||
|
||||
//allowedActions.push("createVm"); // For Beta2, this simply doesn't work without a network.
|
||||
@ -1560,7 +1560,7 @@
|
||||
else {
|
||||
allowedActions.push("edit");
|
||||
|
||||
if(jsonObj.zoneid != null || jsonObj.zoneid != "-1")
|
||||
if(havingSwift == false)
|
||||
allowedActions.push("copyISO");
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user