Angular Code:
$scope.displayTaskOutput = function() {
alert("hey display...")
console.log("Selected jobId is...."+$scope.widgetForm.query_config.selectedTasks.jobId)
console.log("Selected File is....."+$scope.widgetForm.query_config.selectedFiles)
$http({
url: baseUrl+"/"+$scope.widgetForm.query_config.selectedTasks.jobId+"/download",
method: "GET",
params: {fileName:$scope.widgetForm.query_config.selectedFiles},
headers: {
'x-api-key': apiKey,
'Content-Type': 'application/binary'
},
data: ''
}).then(function(response, status) {
console.log("Success data.....")
console.log(response);
$scope.taskOutputData = response.data;
})
};
Html代码:
此处图像未呈现,但有些内容以加密格式呈现。 http调用的输出是原始格式。如何转换为图像