mirror of https://github.com/apache/cloudstack.git
localize Download ISO success/fail message.
This commit is contained in:
parent
db06fe28b0
commit
d3fe06eddc
|
|
@ -6,7 +6,8 @@ label.numretries = Number of Retries
|
|||
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.
|
||||
|
||||
message.download.ISO=Please click <a href="#">#</a> to download ISO
|
||||
|
||||
#Labels
|
||||
label.account.id=Account ID
|
||||
label.account.name=Account Name
|
||||
|
|
|
|||
|
|
@ -16,7 +16,8 @@ dictionary = {
|
|||
'label.action.copy.ISO.processing' : '<fmt:message key="label.action.copy.ISO.processing"/>',
|
||||
'label.action.create.vm' : '<fmt:message key="label.action.create.vm"/>',
|
||||
'label.action.create.vm.processing' : '<fmt:message key="label.action.create.vm.processing"/>',
|
||||
'label.action.download.ISO' : '<fmt:message key="label.action.download.ISO"/>'
|
||||
'label.action.download.ISO' : '<fmt:message key="label.action.download.ISO"/>',
|
||||
'message.download.ISO' : '<fmt:message key="message.download.ISO"/>'
|
||||
};
|
||||
</script>
|
||||
|
||||
|
|
|
|||
|
|
@ -727,11 +727,19 @@ function doDownloadISO($actionLink, $detailsTab, $midmenuItem1) {
|
|||
$infoContainer.removeClass("error");
|
||||
$infoContainer.find("#icon,#info").removeClass("error");
|
||||
var url = decodeURIComponent(json.queryasyncjobresultresponse.jobresult.iso.url);
|
||||
var htmlMsg = "Please click <a href='" + url + "'>" + url + "</a>" + " to download ISO";
|
||||
$infoContainer.find("#info").html(htmlMsg);
|
||||
var htmlMsg = dictionary["message.download.ISO"];
|
||||
var htmlMsg2 = htmlMsg.replace(/#/g, url);
|
||||
$infoContainer.find("#info").html(htmlMsg2);
|
||||
$infoContainer.show();
|
||||
} else if (result.jobstatus == 2) { // Failed
|
||||
handleErrorInDialog2(fromdb(result.jobresult.errortext), $dialogDownloadISO);
|
||||
} else if (result.jobstatus == 2) { // Failed
|
||||
var label = $actionLink.data("label");
|
||||
var label2;
|
||||
if(label in dictionary)
|
||||
label2 = dictionary[label];
|
||||
else
|
||||
label2 = label;
|
||||
var errorMsg = label2 + " - " + g_dictionary["label.failed"] + " - " + g_dictionary["label.error.code"] + " " + fromdb(result.jobresult.errorcode);
|
||||
handleErrorInDialog2(errorMsg, $dialogDownloadISO);
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
|
|||
Loading…
Reference in New Issue