wild card UI done
This commit is contained in:
@@ -311,7 +311,23 @@ app.util = (function(app){
|
||||
return obj;
|
||||
};
|
||||
|
||||
function downloadFile(filename, text){
|
||||
// https://stackoverflow.com/a/18197341
|
||||
|
||||
var element = document.createElement('a');
|
||||
element.setAttribute('href', 'data:text/plain;charset=utf-8,' + encodeURIComponent(text));
|
||||
element.setAttribute('download', filename);
|
||||
|
||||
element.style.display = 'none';
|
||||
document.body.appendChild(element);
|
||||
|
||||
element.click();
|
||||
|
||||
document.body.removeChild(element);
|
||||
}
|
||||
|
||||
return {
|
||||
downloadFile: downloadFile,
|
||||
getUrlParameter: getUrlParameter,
|
||||
actionMessage: actionMessage
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user